flocon/home/programs/swaylock.nix
Anthony Rodriguez 2ac966be49
treewide: global refactor towards a better module structure
Initially, I was using a weird combination of options in order to apply
my theme dynamically. I was setting a read-only option from inside my
modules, which was then used in every application that required it. What
I ended up doing is refactoring everything in order to be inside of my
theme module, and automatically configured when enabled, without doing
any mkMerge/mkIf shenanigans in my other pieces of configuration. This
is healthier, although it should be split up as the theme/default.nix
got quite big.
2024-11-26 18:01:46 +01:00

24 lines
570 B
Nix

{pkgs, ...}: {
# requires `security.pam.services.swaylock = { };` at the system level or else
# unlock will not work.
programs.swaylock = {
enable = true;
package = pkgs.swaylock-effects;
settings = {
clock = true;
timestr = "%H:%M";
indicator = true;
indicator-radius = 111;
indicator-thickness = 9;
screenshots = true;
effect-blur = "7x5";
effect-vignette = "0.75:0.75";
effect-pixelate = 5;
ignore-empty-password = false; # needed for PAM to work with fprintd / password
};
};
}