forked from pub-solar/os
fix: swayidle 'command not found' and screen not
switching off after swaylock locks the screen
This commit is contained in:
parent
98988d0268
commit
e15f6ad4ea
|
@ -12,13 +12,12 @@
|
|||
};
|
||||
Service = {
|
||||
Type = "simple";
|
||||
Environment = "PATH=/run/current-system/sw/bin:${pkgs.sway}/bin:${pkgs.swaylock-bg}/bin:${pkgs.swayidle}/bin";
|
||||
ExecStart = ''
|
||||
swayidle -w \
|
||||
after-resume 'swaymsg "output * dpms on"' \
|
||||
before-sleep 'swaylock-bg' \
|
||||
timeout 300 'swaylock-bg' \
|
||||
timeout 600 'swaymsg "output * dpms off"' resume 'swaymsg "output * dpms on"'
|
||||
${pkgs.swayidle}/bin/swayidle -w \
|
||||
timeout 300 '${pkgs.swaylock-bg}/bin/swaylock-bg' \
|
||||
timeout 600 '${pkgs.sway}/bin/swaymsg "output * dpms off"' \
|
||||
resume '${pkgs.sway}/bin/swaymsg "output * dpms on"' \
|
||||
before-sleep '${pkgs.swaylock-bg}/bin/swaylock-bg'
|
||||
'';
|
||||
};
|
||||
Install = {
|
||||
|
|
|
@ -16,5 +16,5 @@ with self; ''
|
|||
do
|
||||
LOCKARGS="''${LOCKARGS} --image ''${OUTPUT}:''${IMAGE}"
|
||||
done
|
||||
exec ${swaylock}/bin/swaylock $LOCKARGS
|
||||
exec ${swaylock}/bin/swaylock --daemonize $LOCKARGS
|
||||
''
|
||||
|
|
Loading…
Reference in a new issue