Summary Files Commits Branches @commit @diff @stats
diff options
context:
space:
mode:
2 files changed, 15 insertions, 2 deletions
-rw-r--r--packages.nix2
-rw-r--r--services.nix15
diff --git a/packages.nix b/packages.nix
index 9f62bb2..fd5bdcf 100644
--- a/packages.nix
+++ b/packages.nix
@@ -50,7 +50,7 @@ in {
# window manager, compositor, taskbar, notifications, app menu, lockscreen, session manager
openbox lxappearance obconf picom tint2 dunst jgmenu i3lock-color lightdm lightdm-gtk-greeter
# General X11 tools
- lxqt.lxqt-policykit xorg.xev xfontsel xorg.xmodmap xorg.xwininfo xorg.xprop clipnotify xdotool xss-lock xcape xorg.setxkbmap xkbmon xorg.xhost xclip
+ lxqt.lxqt-policykit xorg.xev xfontsel xorg.xmodmap xorg.xwininfo xorg.xprop clipnotify xdotool xautolock xcape xorg.setxkbmap xkbmon xorg.xhost xclip
devilspie2 sxhkd
];
laptop = [
diff --git a/services.nix b/services.nix
index e7f89cf..f185411 100644
--- a/services.nix
+++ b/services.nix
@@ -17,6 +17,19 @@
TimeoutStopSec = 10;
};
};
+
+ };
+
+ systemd.services = {
+ lockscreen = {
+ wantedBy = [ "sleep.target" ];
+ before = [ "suspend.target" ];
+ serviceConfig = {
+ User = "kamen";
+ Environment = [ "DISPLAY=:0" "PATH=/run/current-system/sw/bin" "DBUS_SESSION_BUS_ADDRESS=\"unix:path=/run/user/1000/bus\"" ];
+ ExecStart = "/home/kamen/.a/sys/lock.sh";
+ };
+ };
};
services = {
@@ -73,7 +86,7 @@
enable = true;
time = 15;
locker = "/home/kamen/.a/sys/lock.sh";
- extraOptions = [ "-detectsleep" "-lockaftersleep" "-secure" ];
+ extraOptions = [ "-detectsleep" "-secure" ];
};
};
};