kill and start only current user's session (#829)
This commit is contained in:
parent
cb5d88c8f3
commit
06bec85238
2 changed files with 4 additions and 4 deletions
|
@ -10,8 +10,8 @@ esac
|
||||||
|
|
||||||
cmds="\
|
cmds="\
|
||||||
🔒 lock slock
|
🔒 lock slock
|
||||||
🚪 leave dwm kill -TERM $(pidof -s dwm)
|
🚪 leave dwm kill -TERM $(pgrep -u $USER "\bdwm$")
|
||||||
♻ renew dwm kill -HUP $(pidof -s dwm)
|
♻ renew dwm kill -HUP $(pgrep -u $USER "\bdwm$")
|
||||||
🐻 hibernate ${hib:-sudo -A systemctl suspend-then-hibernate}
|
🐻 hibernate ${hib:-sudo -A systemctl suspend-then-hibernate}
|
||||||
🔃 reboot ${reb:-sudo -A reboot}
|
🔃 reboot ${reb:-sudo -A reboot}
|
||||||
🖥 shutdown ${shut:-sudo -A shutdown -h now}"
|
🖥 shutdown ${shut:-sudo -A shutdown -h now}"
|
||||||
|
|
|
@ -131,8 +131,8 @@ ex=🎯:\
|
||||||
[ ! -f ${XDG_CONFIG_HOME:-$HOME/.config}/shortcutrc ] && shortcuts >/dev/null 2>&1 &
|
[ ! -f ${XDG_CONFIG_HOME:-$HOME/.config}/shortcutrc ] && shortcuts >/dev/null 2>&1 &
|
||||||
|
|
||||||
if pacman -Qs libxft-bgra >/dev/null 2>&1; then
|
if pacman -Qs libxft-bgra >/dev/null 2>&1; then
|
||||||
# Start graphical server on tty1 if not already running.
|
# Start graphical server on user's current tty if not already running.
|
||||||
[ "$(tty)" = "/dev/tty1" ] && ! pidof Xorg >/dev/null 2>&1 && exec startx
|
[[ -n "$(tty)" && -z $(pgrep -u $USER "\bXorg$") ]] && exec startx
|
||||||
else
|
else
|
||||||
echo "\033[31mIMPORTANT\033[0m: Note that \033[32m\`libxft-bgra\`\033[0m must be installed for this build of dwm.
|
echo "\033[31mIMPORTANT\033[0m: Note that \033[32m\`libxft-bgra\`\033[0m must be installed for this build of dwm.
|
||||||
Please run:
|
Please run:
|
||||||
|
|
Loading…
Reference in a new issue