create mango-session.target
This commit is contained in:
parent
207dac004e
commit
e7b71de3d8
14 changed files with 137 additions and 8 deletions
|
|
@ -1,15 +1,19 @@
|
|||
# Waybar is attached to mango-session.target instead of default.target to avoid
|
||||
# startup races in TTY-launched Wayland sessions. The target is started only
|
||||
# after mango exports WAYLAND_DISPLAY/DBUS env into systemd --user.
|
||||
[Unit]
|
||||
Description=Waybar
|
||||
Documentation=man:waybar(5)
|
||||
After=default.target
|
||||
PartOf=default.target
|
||||
PartOf=mango-session.target
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
# Guard against rare timing jitter: do not exec waybar until the compositor
|
||||
# socket actually exists for the display advertised in user-manager env.
|
||||
ExecStartPre=/usr/bin/sh -c 'until [ -n "$WAYLAND_DISPLAY" ] && [ -S "$XDG_RUNTIME_DIR/$WAYLAND_DISPLAY" ]; do sleep 0.2; done'
|
||||
ExecStart=/usr/bin/waybar
|
||||
Restart=on-failure
|
||||
RestartSec=1
|
||||
|
||||
[Install]
|
||||
WantedBy=default.target
|
||||
WantedBy=mango-session.target
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue