1
0
mirror of https://github.com/kmein/niveum synced 2026-03-16 18:21:07 +01:00
Files
niveum/configs/xautolock.nix
Kierán Meinhardt 7860e20900 i3: use i3lock
2019-06-08 15:00:57 +02:00

17 lines
547 B
Nix

{ config, pkgs, ... }:
{
services.xserver.displayManager.sessionCommands = ''
${pkgs.systemd}/bin/systemctl --user import-environment XDG_SESSION_PATH
${pkgs.lightlocker}/bin/light-locker &
'';
services.xserver.xautolock = rec {
enable = true;
killer = "${pkgs.systemd}/bin/systemctl suspend";
locker = "${pkgs.i3lock}/bin/i3lock";
nowlocker = locker;
enableNotifier = true;
notifier = ''${pkgs.libnotify}/bin/notify-send -u normal -a xautolock "Locking soon" "The screen will lock in 10 seconds."'';
};
}