further refinements

This commit is contained in:
Barrett Ruth 2026-02-10 23:09:34 -05:00
parent 0c2b2cee68
commit 2d030ab678
Signed by: barrett
GPG key ID: A6C96C9349D2FC81
14 changed files with 330 additions and 282 deletions

35
home/modules/hypridle.nix Normal file
View file

@ -0,0 +1,35 @@
{
lib,
...
}:
let
isNixOS = builtins.pathExists /etc/NIXOS;
in
{
services.hypridle = {
enable = true;
package = lib.mkIf (!isNixOS) null;
settings = {
general = {
lock_cmd = "wp lock && hyprlock";
after_sleep_cmd = "hyprctl dispatch dpms on";
};
listener = [
{
timeout = 300;
on-timeout = "wp lock && hyprlock";
}
{
timeout = 600;
on-timeout = "hyprctl dispatch dpms off";
on-resume = "hyprctl dispatch dpms on";
}
{
timeout = 1800;
on-timeout = "systemctl suspend";
}
];
};
};
}