aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/dot_config/systemd/user
diff options
context:
space:
mode:
Diffstat (limited to 'dot_config/systemd/user')
-rw-r--r--dot_config/systemd/user/wob.service16
1 files changed, 16 insertions, 0 deletions
diff --git a/dot_config/systemd/user/wob.service b/dot_config/systemd/user/wob.service
new file mode 100644
index 0000000..3a4268f
--- /dev/null
+++ b/dot_config/systemd/user/wob.service
@@ -0,0 +1,16 @@
+[Unit]
+Description=Wayland overlay bar (volume / brightness OSD)
+PartOf=graphical-session.target
+After=graphical-session.target
+ConditionEnvironment=WAYLAND_DISPLAY
+
+[Service]
+Type=simple
+ExecStartPre=/usr/bin/sh -c 'rm -f "$XDG_RUNTIME_DIR/wob.sock" && mkfifo "$XDG_RUNTIME_DIR/wob.sock"'
+ExecStart=/usr/bin/sh -c 'exec /usr/bin/wob <"$XDG_RUNTIME_DIR/wob.sock"'
+ExecStopPost=/usr/bin/rm -f %t/wob.sock
+Restart=on-failure
+RestartSec=2s
+
+[Install]
+WantedBy=sway-session.target