correct swayidle events notation

This commit is contained in:
2026-06-20 10:02:11 +02:00
parent 58842ceaf5
commit 58834947e6
2 changed files with 12 additions and 28 deletions
+6 -10
View File
@@ -31,16 +31,12 @@
services = { services = {
swayidle = { swayidle = {
enable = true; enable = true;
events = [ events = {
{ "before-sleep" = "${pkgs.swaylock}/bin/swaylock";
event = "before-sleep"; "lock" = "${pkgs.swaylock}/bin/swaylock -fF";
command = "${pkgs.swaylock}/bin/swaylock"; "after-resume" = "${pkgs.sway}/bin/swaymsg 'output * dpms on'";
} "unlock" = "${pkgs.sway}/bin/swaymsg 'output * dpms on'";
{ };
event = "lock";
command = "${pkgs.swaylock}/bin/swaylock -fF";
}
];
timeouts = [ timeouts = [
{ {
timeout = 300; timeout = 300;
+6 -18
View File
@@ -318,24 +318,12 @@
services = { services = {
swayidle = { swayidle = {
enable = true; enable = true;
events = [ events = {
{ "before-sleep" = "${pkgs.swaylock}/bin/swaylock";
event = "before-sleep"; "lock" = "${pkgs.swaylock}/bin/swaylock -fF";
command = "${pkgs.swaylock}/bin/swaylock"; "after-resume" = "${pkgs.sway}/bin/swaymsg 'output * dpms on'";
} "unlock" = "${pkgs.sway}/bin/swaymsg 'output * dpms on'";
{ };
event = "lock";
command = "${pkgs.swaylock}/bin/swaylock -fF";
}
{
event = "after-resume";
command = "${pkgs.sway}/bin/swaymsg 'output * dpms on'";
}
{
event = "unlock";
command = "${pkgs.sway}/bin/swaymsg 'output * dpms on'";
}
];
timeouts = [ timeouts = [
{ {
timeout = 300; timeout = 300;