Desktop usability adjustments (#1)

Reviewed-on: #1
This commit is contained in:
2025-05-18 12:56:42 +00:00
parent 1d2b3f799d
commit d91ebe083d
42 changed files with 1649 additions and 1403 deletions

View File

@@ -0,0 +1,37 @@
{inputs, pkgs, ...}:
{
services.hypridle = {
enable = true;
settings = {
general = {
lock_cmd = "pidof hyprlock || hyprlock"; # avoid starting multiple hyprlock instances.
after_sleep_cmd = "hyprctl dispatch dpms on";
ignore_dbus_inhibit = false;
};
listener = [
{
# dim screen after 4 minutes
timeout = 240;
on-timeout = "brightnessctl -s set 10";
# set monitor backlight to minimum, avoid 0 on OLED monitor.
on-resume = "brightnessctl -r";
# monitor backlight restore.
}
{
# lock screen after 5 minutes
timeout = 300;
on-timeout = "loginctl lock-session && hyprctl dispatch dpms off";
on-resume = "hyprctl dispatch dpms on";
}
{
# suspend after 10 minutes
timeout = 600;
on-timeout = "systemctl suspend";
on-resume = "hyprctl dispatch dpms on";
}
];
};
};
}