feat: adjust idle times; nixfmt

This commit is contained in:
etwas 2025-12-08 14:09:38 +01:00
parent b8222703d9
commit 28059709b0

View file

@ -1,15 +1,26 @@
{ pkgs, ... }: {
{ pkgs, ... }:
{
services.swayidle = {
enable = true;
systemdTarget = "graphical-session.target";
events = [
{ event = "before-sleep"; command = "${pkgs.swaylock}/bin/swaylock -fF"; }
{
event = "before-sleep";
command = "${pkgs.swaylock}/bin/swaylock -fF";
}
];
timeouts = [
{
timeout = 300;
command = "${pkgs.swaylock}/bin/swaylock -fF && ${pkgs.niri}/bin/niri msg action power-off-monitors";
}
{
timeout = 1800;
command = "${pkgs.systemd}/bin/systemctl suspend-then-hibernate";
}
];
};
}