You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
14 lines
403 B
Bash
14 lines
403 B
Bash
5 years ago
|
#!/bin/bash
|
||
5 years ago
|
swaylock="$HOME/.config/sway/scripts/lock.sh"
|
||
5 years ago
|
screenon="swaymsg 'output * dpms on'"
|
||
|
screenoff="swaymsg 'output * dpms off'"
|
||
|
swayidle \
|
||
|
lock "$swaylock" \
|
||
5 years ago
|
unlock "pkill -9 swaylock" \
|
||
5 years ago
|
timeout 300 "lqsd -d" \
|
||
|
resume "lqsd -r" \
|
||
5 years ago
|
timeout 600 "loginctl lock-session" \
|
||
|
timeout 610 "$screenoff" \
|
||
5 years ago
|
resume "$screenon; lqsd -r" \
|
||
5 years ago
|
before-sleep "playerctl pause; loginctl lock-session" \
|