/
99-autostart-applications.conf
29 lines (26 loc) · 1.44 KB
/
99-autostart-applications.conf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
# enable idle mode
exec $idle
# autostart background applications
exec /usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1
exec $notifications
# if-exists autostarts
#
exec {
'[ -x "$(command -v flashfocus)" ] && flashfocus'
'[ -x "$(command -v wlsunset)" ] && /usr/share/sway/scripts/sunset.sh "on"'
'[ -x "$(command -v autotiling)" ] && autotiling'
'[ -x "$(command -v foot)" ] && /usr/share/sway/scripts/foot.sh --server'
'[ -x "$(command -v nwg-wrapper)" ] && [ -f $HOME/.config/nwg-wrapper/help.sh ] && /usr/share/sway/scripts/help.sh --restore'
'[ -x "$(command -v wl-paste)" ] && [ -x "$(command -v cliphist)" ] && wl-paste --watch cliphist store'
}
exec_always {
'[ -x "$(command -v spice-vdagent)" ] && spice-vdagent'
# restart kanshi https://github.com/emersion/kanshi/issues/43#issuecomment-531679213
'[ -x "$(command -v kanshi)" ] && pkill kanshi; exec kanshi'
'[ -x "$(command -v sworkstyle)" ] && pkill sworkstyle; sworkstyle &> /tmp/sworkstyle.log'
'[ -x "$(command -v playerctl)" ] && pkill playerctl; playerctl -a metadata --format \'{{status}} {{title}}\' --follow | while read line; do pkill -RTMIN+5 waybar; done'
}
# https://github.com/Alexays/Waybar/issues/1093#issuecomment-841846291
exec systemctl --user import-environment DISPLAY WAYLAND_DISPLAY SWAYSOCK
exec hash dbus-update-activation-environment 2>/dev/null && \
dbus-update-activation-environment --systemd DISPLAY WAYLAND_DISPLAY SWAYSOCK