fix swayidle
This commit is contained in:
parent
a5c383ed14
commit
468a0d2850
|
@ -18,7 +18,7 @@ let
|
|||
systemctl suspend
|
||||
'';
|
||||
_sway_idle_toggle = pkgs.writeShellScriptBin "_sway_idle_toggle" ''
|
||||
if pidof swayidle > /dev/null; then
|
||||
if systemctl --user status swayidle > /dev/null; then
|
||||
systemctl --user stop swayidle.service
|
||||
else
|
||||
systemctl --user start swayidle.service
|
||||
|
|
|
@ -88,7 +88,7 @@ in {
|
|||
"sway/language" = { format = "{short} {variant}"; };
|
||||
"custom/caffeine" = {
|
||||
format = "{}";
|
||||
exec = "pidof swayidle > /dev/null && echo 鈴 || echo ";
|
||||
exec = "systemctl --user status swayidle > /dev/null && echo 鈴 || echo ";
|
||||
on-click = "_sway_idle_toggle";
|
||||
interval = 1;
|
||||
tooltip = false;
|
||||
|
|
Loading…
Reference in a new issue