summaryrefslogtreecommitdiffstats
path: root/guix/jd/home/services/desktop.scm
diff options
context:
space:
mode:
Diffstat (limited to 'guix/jd/home/services/desktop.scm')
-rw-r--r--guix/jd/home/services/desktop.scm198
1 files changed, 0 insertions, 198 deletions
diff --git a/guix/jd/home/services/desktop.scm b/guix/jd/home/services/desktop.scm
deleted file mode 100644
index 393c2d0..0000000
--- a/guix/jd/home/services/desktop.scm
+++ /dev/null
@@ -1,198 +0,0 @@
1(define-module (jd home services desktop)
2 #:use-module (gnu packages)
3 #:use-module (gnu packages freedesktop)
4 #:use-module (gnu packages networking)
5 #:use-module (gnu packages syncthing)
6 #:use-module (gnu packages gnome)
7 #:use-module (gnu packages gnupg)
8 #:use-module (gnu services)
9 #:use-module (gnu services configuration)
10 #:use-module (gnu home services)
11 #:use-module (gnu home services shepherd)
12 #:use-module (gnu home services desktop)
13 #:use-module (gnu home services sound)
14 #:use-module (gnu home services xdg)
15 #:use-module (gnu home services gnupg)
16 #:use-module (gnu home services dotfiles)
17 #:use-module (guix gexp)
18
19 #:use-module (jd packages fonts))
20
21(define (desktop-profile-service config)
22 (append
23 (list font-terminus-ttf)
24 (specifications->packages '("sway"
25 ;; "swayfx"
26 "swaylock"
27 "swayidle"
28 "swaynotificationcenter"
29 "waybar"
30 "fuzzel"
31 "foot"
32 "mako"
33 "wl-clipboard"
34 "wlsunset"
35 "grimshot"
36 "swappy"
37
38 "htop"
39 "distrobox"
40
41 "udiskie"
42 ;; rest
43 "qutebrowser"
44 "ungoogled-chromium"
45 "firefox"
46 "tor-client"
47 "signal-desktop"
48
49 "pulsemixer"
50 "pavucontrol"
51 "alsa-utils"
52
53 "virt-manager"
54
55 "flatpak"
56 "redshift"
57 "fontmanager"
58
59 "polybar"
60
61 "blueman"
62
63 "nomacs"
64
65 "xdg-utils"
66 "xdg-dbus-proxy"
67 "xdg-desktop-portal-gtk"
68 "xdg-desktop-portal-wlr"
69 "glib:bin"
70 "gtk+:bin"
71 "gnome-keyring"
72 "shared-mime-info"
73 "libnotify"
74 "dconf"
75 "hicolor-icon-theme"
76
77 "dunst"
78
79 ; "gimp"
80 ; "inkscape"
81
82 "mpv"
83 "youtube-dl"
84
85 "pamixer"
86 "playerctl"
87 "scrot"
88 "brightnessctl"
89 "upower"
90 "tlp"
91 "feh"
92 "alacritty"
93
94 "curl"
95 "wget"
96 "zip"
97 "unzip"
98 "qrencode"
99 "trash-cli"
100 "pandoc"
101 "password-store"
102 "oath-toolkit"
103 ;; "pinentry"
104
105 "syncthing"
106 "syncthing-gtk"
107
108 "xmodmap"
109 "xrandr"
110 "arandr"
111 "xss-lock"
112 "libinput"
113 "xinput"
114 "xprop"
115 "rlwrap"
116
117 "nheko"
118 "quassel"
119 "inkscape"
120 "gimp"
121 "libreoffice"
122 "steam"))))
123
124(define (desktop-environment-variables-service config)
125 `(("GTK_THEME" . "Adwaita:dark")
126 ("VISUAL" . "emacsclient")
127 ("EDITOR" . "emacsclient")
128 ("PATH" . "$HOME/.bin:$HOME/.local/bin:$HOME/.npm-global/bin:$PATH")
129 ("XDG_DATA_DIRS" . "$XDG_DATA_DIRS:$HOME/.local/share/flatpak/exports/share")
130 ("SBCL_HOME" . "/run/current-system/profile/lib/sbcl/")
131
132 ;; Set Wayland-specific environment variables (taken from RDE)
133 ("XDG_CURRENT_DESKTOP" . "sway")
134 ("XDG_SESSION_TYPE" . "wayland")
135 ("RTC_USE_PIPEWIRE" . "true")
136 ("SDL_VIDEODRIVER" . "wayland")
137 ("MOZ_ENABLE_WAYLAND" . "1")
138 ("CLUTTER_BACKEND" . "wayland")
139 ("ELM_ENGINE" . "wayland_egl")
140 ("ECORE_EVAS_ENGINE" . "wayland-egl")
141 ("QT_QPA_PLATFORM" . "wayland-egl"))) ;; QT_QPA_PLATFORM=xcb
142
143(define (desktop-xdg-mime-applications-service config)
144 (home-xdg-mime-applications-configuration
145 (default '((inode/directory . emacsclient.desktop)
146 (application/pdf . emacsclient.desktop)
147 (x-scheme-handler/http= . firefox.desktop)
148 (x-scheme-handler/https= . firefox.desktop)))
149 ;; (desktop-entries
150 ;; (list (xdg-desktop-entry
151 ;; (file "emacs-desktop")
152 ;; (name "Emacs")
153 ;; (type 'application)
154 ;; (config
155 ;; '((exec . "emacsclient -a emacs %u"))))))
156 ))
157
158(define (desktop-gpg-agent-service config)
159 (home-gpg-agent-configuration
160 (pinentry-program
161 (file-append pinentry-gnome3 "/bin/pinentry-gnome3"))
162 (ssh-support? #t)
163 (default-cache-ttl 28800)
164 (max-cache-ttl 28800)
165 (default-cache-ttl-ssh 28800)
166 (max-cache-ttl-ssh 28800)))
167
168(define (desktop-gpg-agent-service config)
169 (home-gpg-agent-configuration
170 (pinentry-program
171 (file-append pinentry-gnome3 "/bin/pinentry-gnome3"))
172 (ssh-support? #t)
173 (default-cache-ttl 28800)
174 (max-cache-ttl 28800)
175 (default-cache-ttl-ssh 28800)
176 (max-cache-ttl-ssh 28800)))
177
178(define (desktop-dotfiles-service config)
179 (home-dotfiles-configuration
180 (directories '("./files"))))
181
182(define-public home-desktop-service-type
183 (service-type (name 'home-desktop)
184 (extensions (list (service-extension home-profile-service-type
185 desktop-profile-service)
186 (service-extension home-environment-variables-service-type
187 desktop-environment-variables-service)
188 (service-extension home-pipewire-service-type
189 (lambda (_) (home-pipewire-configuration)))
190 (service-extension home-xdg-mime-applications-service-type
191 desktop-xdg-mime-applications-service)
192 (service-extension home-gpg-agent-service-type
193 desktop-gpg-agent-service)
194 (service-extension home-dotfiles-service-type
195 desktop-dotfiles-service)))
196 (default-value #f)
197 (description "Runs desktop services.")))
198