lock: More goodness
This commit is contained in:
parent
82bafb3428
commit
b3f1d95634
|
@ -190,6 +190,16 @@
|
|||
# toolbox
|
||||
imagemagick
|
||||
numbat
|
||||
|
||||
# Locker
|
||||
(pkgs.writeShellApplication {
|
||||
name = "lock";
|
||||
text = ''
|
||||
${config.frogeye.hooks.lock}
|
||||
|
||||
${pkgs.vlock}/bin/vlock --all
|
||||
'';
|
||||
})
|
||||
];
|
||||
sessionVariables = {
|
||||
# Favourite commands
|
||||
|
|
|
@ -19,10 +19,7 @@ in
|
|||
name = "xlock";
|
||||
text = ''
|
||||
${config.frogeye.hooks.lock}
|
||||
# TODO Maybe we could have a terminal lock? With vlock.
|
||||
|
||||
# TODO Does that work for all DMs?
|
||||
# TODO Might want to use i3lock on NixOS configs still?
|
||||
# TODO Reevaluate whether we want this or not
|
||||
if ! ${pkgs.lightdm}/bin/dm-tool lock
|
||||
then
|
||||
if [ -d ${config.xdg.cacheHome}/lockpatterns ]
|
||||
|
@ -50,9 +47,9 @@ in
|
|||
"${mod}+F5" = "exec --no-startup-id ${pkgs.xautolock}/bin/xautolock -enable";
|
||||
};
|
||||
startup = [
|
||||
# Lock screen after 10 minutes
|
||||
# Stop screen after 10 minutes, 1 minutes after lock it
|
||||
{ notification = false; command = "${pkgs.xautolock}/bin/xautolock -time 10 -locker '${pkgs.xorg.xset}/bin/xset dpms force standby' -killtime 1 -killer xlock"; }
|
||||
# TODO There's a services.screen-locker.xautolock but not sure it can match the above command
|
||||
# services.screen-locker.xautolock is hardcoded to use systemd for -locker (doesn't even work...)
|
||||
];
|
||||
};
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue