separate hyprland config

This commit is contained in:
Tristan 2024-01-05 18:46:17 +00:00
parent a90de57f7e
commit 7cbdcdcd87
7 changed files with 380 additions and 303 deletions

28
lib/programs/swayidle.nix Normal file
View file

@ -0,0 +1,28 @@
{pkgs,...}: {
services.swayidle = {
enable = true;
systemdTarget = "graphical-session.target";
events = [
{
event = "before-sleep";
command = "${pkgs.swaylock-effects}/bin/swaylock";
}
{
event = "lock";
command = "${pkgs.swaylock-effects}/bin/swaylock";
}
];
timeouts = [
{
timeout = 300;
command = "${pkgs.swaylock-effects}/bin/swaylock -f";
}
{
timeout = 600;
command = "systemctl suspend";
}
];
};
}