[s6] swayidle: use env vars to set timeouts
This commit is contained in:
parent
06bd09c469
commit
abe6ca39ee
3
.profile
3
.profile
|
@ -7,6 +7,9 @@ export XDG_CONFIG_HOME="$HOME/.config"
|
|||
export PYTHON_KEYRING_BACKEND=keyring.backends.null.Keyring
|
||||
export S6_SCANDIR="$HOME/.s6/scandir"
|
||||
|
||||
export SWAYIDLE_LOCK=300
|
||||
export SWAYIDLE_TURN_OFF=600
|
||||
|
||||
export GTK_THEME=Arc
|
||||
|
||||
export LESS="-R -z-2 -j4"
|
||||
|
|
|
@ -1,7 +1,9 @@
|
|||
#!/bin/execlineb -P
|
||||
importas SWAYIDLE_LOCK SWAYIDLE_LOCK
|
||||
importas SWAYIDLE_TURN_OFF SWAYIDLE_TURN_OFF
|
||||
swayidle -w
|
||||
timeout 300 "swaylock -f"
|
||||
timeout 600 "toggle_monitors off"
|
||||
timeout ${SWAYIDLE_LOCK} "swaylock -f"
|
||||
timeout ${SWAYIDLE_TURN_OFF} "toggle_monitors off"
|
||||
resume "toggle_monitors on"
|
||||
after-resume "toggle_monitors on"
|
||||
before-sleep "swaylock -f"
|
||||
|
|
Loading…
Reference in a new issue