Disaple suspend on gospel
Some checks failed
Gitea Actions Demo / Explore-Gitea-Actions (push) Failing after 0s

This commit is contained in:
alejandro-angulo 2025-09-01 12:49:40 -07:00
parent 61f8ecf26b
commit 6ddc91780f
Signed by: alejandro-angulo
GPG key ID: 75579581C74554B6
2 changed files with 10 additions and 2 deletions

View file

@ -42,6 +42,13 @@ in
Timeout in seconds before suspending the system
'';
};
suspendEnable = mkOption {
type = types.bool;
default = true;
description = ''
Whether or not to automatically suspend
'';
};
brightnessTimeout = mkOption {
type = types.int;
@ -99,10 +106,10 @@ in
on-resume = "hyprctl dispatch dpms on && ${pkgs.brightnessctl}/bin/brightnessctl -r";
}
# Suspend system
{
(lib.mkIf cfg.suspendEnable {
timeout = cfg.suspendTimeout;
on-timeout = "systemctl suspend";
}
})
];
};
};