replace swaylock with nova-shell lock

This commit is contained in:
müde 2026-04-17 12:47:51 +02:00
parent 3c8024045e
commit 4c82ecd2b9
5 changed files with 42 additions and 42 deletions

View file

@ -0,0 +1,27 @@
{ pkgs, ... }:
{
services.swayidle =
let
lock-command = "${pkgs.systemd}/bin/loginctl lock-session";
in
{
enable = true;
systemdTarget = "graphical-session.target";
timeouts = [
{
timeout = 30;
command = lock-command;
}
{
timeout = 60 * 10;
command = "${pkgs.systemd}/bin/systemctl suspend";
}
];
events = [
{
event = "before-sleep";
command = "${pkgs.playerctl}/bin/playerctl pause; ${lock-command}";
}
];
};
}