nixpkgs/nixos/modules/programs/wayland/hyprlock.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

26 lines
653 B
Nix
Raw Normal View History

2024-05-27 02:57:24 -06:00
{ lib, pkgs, config, ... }:
let
cfg = config.programs.hyprlock;
in
{
options.programs.hyprlock = {
enable = lib.mkEnableOption "hyprlock, Hyprland's GPU-accelerated screen locking utility";
package = lib.mkPackageOption pkgs "hyprlock" { };
};
config = lib.mkIf cfg.enable {
environment.systemPackages = [
cfg.package
];
# Hyprlock needs Hypridle systemd service to be running to detect idle time
2024-05-27 06:11:36 -06:00
services.hypridle.enable = true;
2024-05-27 02:57:24 -06:00
# Hyprlock needs PAM access to authenticate, else it fallbacks to su
security.pam.services.hyprlock = {};
};
meta.maintainers = with lib.maintainers; [ johnrtitor ];
}