mirror of
https://github.com/SebastianStork/nixos-config.git
synced 2026-01-21 16:21:34 +01:00
Unify idle behavior
This commit is contained in:
parent
bf0faf55c0
commit
251c663781
2 changed files with 12 additions and 13 deletions
|
|
@ -1,5 +1,6 @@
|
||||||
{
|
{
|
||||||
config,
|
config,
|
||||||
|
pkgs,
|
||||||
lib,
|
lib,
|
||||||
wrappers,
|
wrappers,
|
||||||
...
|
...
|
||||||
|
|
@ -23,10 +24,20 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
listener = [
|
listener = [
|
||||||
|
{
|
||||||
|
timeout = 300;
|
||||||
|
on-timeout = "${lib.getExe pkgs.brightnessctl} -s && ${lib.getExe pkgs.brightnessctl} -e set 10%";
|
||||||
|
on-resume = "${lib.getExe pkgs.brightnessctl} -r";
|
||||||
|
}
|
||||||
{
|
{
|
||||||
timeout = 600;
|
timeout = 600;
|
||||||
on-timeout = "loginctl lock-session";
|
on-timeout = "loginctl lock-session";
|
||||||
}
|
}
|
||||||
|
{
|
||||||
|
timeout = 610;
|
||||||
|
on-timeout = "hyprctl dispatch dpms off";
|
||||||
|
on-resume = "hyprctl dispatch dpms on";
|
||||||
|
}
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
{ pkgs, lib, ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
imports = [ ./default.nix ];
|
imports = [ ./default.nix ];
|
||||||
|
|
||||||
|
|
@ -6,17 +6,5 @@
|
||||||
myConfig.de.theme = "light";
|
myConfig.de.theme = "light";
|
||||||
|
|
||||||
wayland.windowManager.hyprland.settings.monitor = "eDP-1,1920x1080@60,0x0,1";
|
wayland.windowManager.hyprland.settings.monitor = "eDP-1,1920x1080@60,0x0,1";
|
||||||
|
|
||||||
services.hypridle.settings.listener = [
|
|
||||||
{
|
|
||||||
timeout = 300;
|
|
||||||
on-timeout = "${lib.getExe pkgs.brightnessctl} -s && ${lib.getExe pkgs.brightnessctl} -e set 10%";
|
|
||||||
on-resume = "${lib.getExe pkgs.brightnessctl} -r";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
timeout = 1200;
|
|
||||||
on-timeout = "systemctl suspend";
|
|
||||||
}
|
|
||||||
];
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue