[startsession] return to sh

command is more portable
This commit is contained in:
odrling 2023-12-13 05:10:09 +01:00
parent c47027c216
commit e63f9dd98a
No known key found for this signature in database
GPG key ID: E24CA7508C27AF5B

View file

@ -1,12 +1,11 @@
#!/bin/execlineb -P
importas S6_SCANDIR S6_SCANDIR
ifelse { redirfd -w 1 /dev/null which dwl }
{
export XDG_CURRENT_DESKTOP dwl
export GDK_BACKEND wayland
if -n { pgrep dwl }
foreground { dbus-launch --exit-with-session dwl -s "wlstart" }
s6-svscanctl -t ${S6_SCANDIR}
}
if { redirfd -w 1 /dev/null which startx }
if -n { pgrep xinit } startx
#!/bin/sh
if command -v dwl > /dev/null; then
export XDG_CURRENT_DESKTOP=dwl
export GDK_BACKEND=wayland
pgrep dwl || exec execlineb -Pc "
importas S6_SCANDIR S6_SCANDIR
foreground { dbus-launch --exit-with-session dwl -s wlstart }
s6-svscanctl -t \${S6_SCANDIR}"
elif command -v startx > /dev/null; then
pgrep xinit || exec startx
fi