Diff
1diff --git a/.chezmoiignore b/.chezmoiignore
2index f5a776408873c268b297dc62620d8a767472b0be..f21f319ac183799a5cbd40bef791ea78304e40bf 100644
3--- a/.chezmoiignore
4+++ b/.chezmoiignore
5@@ -6,6 +6,10 @@ us_colemak.patch
6 config_template.yaml
7 .config/nvim/lazy-lock.json
8
9+{{ if not (index . "yubikeyring" | default false) }}
10+.config/systemd/user/protonmail-bridge.service.d/
11+{{- end }}
12+
13 {{ if not (index . "gui" | default false) }}
14 .config/fontconfig
15 .config/fuzzel
16diff --git a/config_template.yaml b/config_template.yaml
17index 7a357d88aecf8b3af4a129e72ac6d6685da89a44..3670cd99755a055d42983bb7f89fd2133cec39fd 100644
18--- a/config_template.yaml
19+++ b/config_template.yaml
20@@ -2,6 +2,7 @@
21 data:
22 gui: true
23 modern_cli: true
24+ yubikeyring: false
25 hyprland:
26 monitors:
27 identifier: "resolution@refresh_rate, auto, 1, vrr, 0"
28diff --git a/dot_config/hypr/hyprland.conf.tmpl b/dot_config/hypr/hyprland.conf.tmpl
29index 0436af679aa3422f526322d65543b37ec4d41d1e..11795259bcdae445d71e77d426fdbb619b7f5548 100644
30--- a/dot_config/hypr/hyprland.conf.tmpl
31+++ b/dot_config/hypr/hyprland.conf.tmpl
32@@ -26,7 +26,6 @@ $animation_speed = 1
33 exec-once = hyprpm reload -n
34
35 exec-once = uwsm app -- firefox.desktop
36-exec-once = uwsm app -- org.mozilla.Thunderbird.desktop
37 exec-once = uwsm app -- org.telegram.desktop.desktop
38 exec-once = uwsm app -- signal.desktop
39 {{- range $_, $app := index .hyprland "additional_autostart" | default list }}
40diff --git a/dot_config/systemd/user/graphical-session.target.wants/symlink_app-com.mitchellh.ghostty.service b/dot_config/systemd/user/graphical-session.target.wants/symlink_app-com.mitchellh.ghostty.service
41new file mode 100644
42index 0000000000000000000000000000000000000000..e82966c97b64b7457a4b008cc383f6c9d104f5a7
43--- /dev/null
44+++ b/dot_config/systemd/user/graphical-session.target.wants/symlink_app-com.mitchellh.ghostty.service
45@@ -0,0 +1 @@
46+/usr/lib/systemd/user/app-com.mitchellh.ghostty.service
47diff --git a/dot_config/systemd/user/graphical-session.target.wants/symlink_hypridle.service b/dot_config/systemd/user/graphical-session.target.wants/symlink_hypridle.service
48new file mode 100644
49index 0000000000000000000000000000000000000000..5301d23ae395d8b5be10e232463c9f534482fe14
50--- /dev/null
51+++ b/dot_config/systemd/user/graphical-session.target.wants/symlink_hypridle.service
52@@ -0,0 +1 @@
53+/usr/lib/systemd/user/hypridle.service
54diff --git a/dot_config/systemd/user/graphical-session.target.wants/symlink_hyprpaper.service b/dot_config/systemd/user/graphical-session.target.wants/symlink_hyprpaper.service
55new file mode 100644
56index 0000000000000000000000000000000000000000..3e5dae915f7103d8eb6429071dc3ab4baddc098f
57--- /dev/null
58+++ b/dot_config/systemd/user/graphical-session.target.wants/symlink_hyprpaper.service
59@@ -0,0 +1 @@
60+/usr/lib/systemd/user/hyprpaper.service
61diff --git a/dot_config/systemd/user/graphical-session.target.wants/symlink_hyprpolkitagent.service b/dot_config/systemd/user/graphical-session.target.wants/symlink_hyprpolkitagent.service
62new file mode 100644
63index 0000000000000000000000000000000000000000..c1bab3afa876db4f50d6af70cf2a5235210d00ab
64--- /dev/null
65+++ b/dot_config/systemd/user/graphical-session.target.wants/symlink_hyprpolkitagent.service
66@@ -0,0 +1 @@
67+/usr/lib/systemd/user/hyprpolkitagent.service
68diff --git a/dot_config/systemd/user/graphical-session.target.wants/symlink_protonmail-bridge.timer b/dot_config/systemd/user/graphical-session.target.wants/symlink_protonmail-bridge.timer
69new file mode 100644
70index 0000000000000000000000000000000000000000..7e1b339a09eb55cb5309110ece7a44c80f171689
71--- /dev/null
72+++ b/dot_config/systemd/user/graphical-session.target.wants/symlink_protonmail-bridge.timer
73@@ -0,0 +1 @@
74+/home/pavle/.config/systemd/user/protonmail-bridge.timer
75diff --git a/dot_config/systemd/user/graphical-session.target.wants/symlink_supersonic.service b/dot_config/systemd/user/graphical-session.target.wants/symlink_supersonic.service
76deleted file mode 100644
77index 1715ba70c2a9d83dd0ddbed0c398ca59f8209f4e..0000000000000000000000000000000000000000
78--- a/dot_config/systemd/user/graphical-session.target.wants/symlink_supersonic.service
79+++ /dev/null
80@@ -1 +0,0 @@
81-/home/pavle/.config/systemd/user/supersonic.service
82diff --git a/dot_config/systemd/user/graphical-session.target.wants/symlink_supersonic.timer b/dot_config/systemd/user/graphical-session.target.wants/symlink_supersonic.timer
83new file mode 100644
84index 0000000000000000000000000000000000000000..34ba24ec871af3d7e09e174eb6b0b8663ef79582
85--- /dev/null
86+++ b/dot_config/systemd/user/graphical-session.target.wants/symlink_supersonic.timer
87@@ -0,0 +1 @@
88+/home/pavle/.config/systemd/user/supersonic.timer
89diff --git a/dot_config/systemd/user/graphical-session.target.wants/symlink_thunderbird-autostart.timer b/dot_config/systemd/user/graphical-session.target.wants/symlink_thunderbird-autostart.timer
90new file mode 100644
91index 0000000000000000000000000000000000000000..5dc3b559fe71a489b674fe6ede13fd0774dba042
92--- /dev/null
93+++ b/dot_config/systemd/user/graphical-session.target.wants/symlink_thunderbird-autostart.timer
94@@ -0,0 +1 @@
95+/home/pavle/.config/systemd/user/thunderbird-autostart.timer
96diff --git a/dot_config/systemd/user/graphical-session.target.wants/symlink_waybar@config-bottom.service b/dot_config/systemd/user/graphical-session.target.wants/symlink_waybar@config-bottom.service
97new file mode 100644
98index 0000000000000000000000000000000000000000..897716c6c5b4f6411e155f58d2cb8135df9f38e4
99--- /dev/null
100+++ b/dot_config/systemd/user/graphical-session.target.wants/symlink_waybar@config-bottom.service
101@@ -0,0 +1 @@
102+/home/pavle/.config/systemd/user/waybar@.service
103diff --git a/dot_config/systemd/user/graphical-session.target.wants/symlink_waybar@config-top.service b/dot_config/systemd/user/graphical-session.target.wants/symlink_waybar@config-top.service
104new file mode 100644
105index 0000000000000000000000000000000000000000..897716c6c5b4f6411e155f58d2cb8135df9f38e4
106--- /dev/null
107+++ b/dot_config/systemd/user/graphical-session.target.wants/symlink_waybar@config-top.service
108@@ -0,0 +1 @@
109+/home/pavle/.config/systemd/user/waybar@.service
110diff --git a/dot_config/systemd/user/protonmail-bridge.service.d/override.conf.tmpl b/dot_config/systemd/user/protonmail-bridge.service.d/override.conf.tmpl
111new file mode 100644
112index 0000000000000000000000000000000000000000..a32e5c81ac10999f309a69c62731f6305b3ded92
113--- /dev/null
114+++ b/dot_config/systemd/user/protonmail-bridge.service.d/override.conf.tmpl
115@@ -0,0 +1,5 @@
116+[Unit]
117+{{- if (index . "yubikeyring" | default false) }}
118+Requires=yubikeyring.service
119+After=yubikeyring.service
120+{{ end }}
121diff --git a/dot_config/systemd/user/protonmail-bridge.timer b/dot_config/systemd/user/protonmail-bridge.timer
122new file mode 100644
123index 0000000000000000000000000000000000000000..d10e7b9155e86f27876c889b120f320dd15389c2
124--- /dev/null
125+++ b/dot_config/systemd/user/protonmail-bridge.timer
126@@ -0,0 +1,9 @@
127+[Unit]
128+Description=Start ProtonMail Bridge after graphical session startup
129+
130+[Timer]
131+OnActiveSec=1s
132+Unit=protonmail-bridge.service
133+
134+[Install]
135+WantedBy=graphical-session.target
136diff --git a/dot_config/systemd/user/supersonic.service b/dot_config/systemd/user/supersonic.service.tmpl
137rename from dot_config/systemd/user/supersonic.service
138rename to dot_config/systemd/user/supersonic.service.tmpl
139index bd84f1d92c46a145c254384c4e41c775319611c5..a2e7429b85554266964ca8e2a17af0f49881d6e9 100644
140--- a/dot_config/systemd/user/supersonic.service
141+++ b/dot_config/systemd/user/supersonic.service.tmpl
142@@ -1,7 +1,9 @@
143 [Unit]
144 Description=Supersonic Music Player
145+{{- if (index . "yubikeyring" | default false) }}
146 After=yubikeyring.service
147 Wants=yubikeyring.service
148+{{- end }}
149
150 [Service]
151 Type=simple
152diff --git a/dot_config/systemd/user/supersonic.timer b/dot_config/systemd/user/supersonic.timer
153new file mode 100644
154index 0000000000000000000000000000000000000000..d6d6b6446f8311360ff1c504965360576e3be3d7
155--- /dev/null
156+++ b/dot_config/systemd/user/supersonic.timer
157@@ -0,0 +1,9 @@
158+[Unit]
159+Description=Start Supersonic after graphical session startup
160+
161+[Timer]
162+OnActiveSec=1s
163+Unit=supersonic.service
164+
165+[Install]
166+WantedBy=graphical-session.target
167diff --git a/dot_config/systemd/user/thunderbird-autostart.service b/dot_config/systemd/user/thunderbird-autostart.service
168new file mode 100644
169index 0000000000000000000000000000000000000000..e8e1f2c1681d1e048f8f7d7d8160e318b8c01689
170--- /dev/null
171+++ b/dot_config/systemd/user/thunderbird-autostart.service
172@@ -0,0 +1,8 @@
173+[Unit]
174+Description=Start Thunderbird after Proton Mail Bridge
175+Requires=protonmail-bridge.service
176+After=protonmail-bridge.service
177+
178+[Service]
179+Type=oneshot
180+ExecStart=/usr/bin/uwsm app -- org.mozilla.Thunderbird.desktop
181diff --git a/dot_config/systemd/user/thunderbird-autostart.timer b/dot_config/systemd/user/thunderbird-autostart.timer
182new file mode 100644
183index 0000000000000000000000000000000000000000..01a4b69c8dc542e0c48a1d4dcc46d6a156c9855d
184--- /dev/null
185+++ b/dot_config/systemd/user/thunderbird-autostart.timer
186@@ -0,0 +1,9 @@
187+[Unit]
188+Description=Start Thunderbird after graphical session startup
189+
190+[Timer]
191+OnActiveSec=1s
192+Unit=thunderbird-autostart.service
193+
194+[Install]
195+WantedBy=graphical-session.target