2019-10-26 20:05:31 +03:00
|
|
|
#!/bin/bash
|
|
|
|
swaylock="$HOME/Scripts/swaylock.sh"
|
|
|
|
dimscreen="$HOME/Scripts/dim-screen.sh"
|
|
|
|
screenon="swaymsg 'output * dpms on'"
|
|
|
|
screenoff="swaymsg 'output * dpms off'"
|
|
|
|
swayidle \
|
|
|
|
lock "$swaylock" \
|
2020-01-19 21:54:25 +02:00
|
|
|
timeout 300 "lqsd -d" \
|
|
|
|
resume "lqsd -r" \
|
2020-01-10 23:45:29 +02:00
|
|
|
timeout 600 "loginctl lock-session $(loginctl show-user $USER -p Sessions | cut -d'=' -f2); sleep 0.5; $screenoff" \
|
2020-01-19 21:56:27 +02:00
|
|
|
resume "$screenon; lqsd -r" \
|
2020-01-10 23:45:29 +02:00
|
|
|
before-sleep "playerctl pause; loginctl lock-session $(loginctl show-user $USER -p Sessions | cut -d'=' -f2)" \
|
2019-10-26 20:05:31 +03:00
|
|
|
unlock "pkill -9 swaylock"
|