Add xautolock

This commit is contained in:
Dave Gallant
2022-05-29 22:51:17 -04:00
parent d2f1a45948
commit 3c9b189021
4 changed files with 26 additions and 14 deletions

View File

@@ -0,0 +1,18 @@
{
config,
pkgs,
...
}: let
in {
systemd.services.xautolock = {
description = "Lock the screen automatically after a timeout";
wantedBy = ["graphical.target"];
serviceConfig = {
Type = "simple";
User = "dave";
Environment = "DISPLAY=:0";
ExecStart = "${pkgs.xautolock}/bin/xautolock -time 1 -detectsleep -locker /home/dave/lock";
};
};
}