added passFF extension

This commit is contained in:
Bryan Ramos 2024-06-19 23:04:21 -04:00
parent b92d485213
commit 6ecf0632cd
Signed by: bryan
GPG key ID: 6ABDCD144D6643C8
3 changed files with 44 additions and 6 deletions

View file

@ -3,9 +3,13 @@
with lib;
let
cfg = config.modules.user.security.gpg;
gui = config.modules.user.gui.wm;
wm = {
enable = builtins.any (mod: mod.enable or false) (builtins.attrValues gui);
};
in
{ options.modules.user.security.gpg = { enable = mkEnableOption "user.security.gpg"; };
{ options.modules.user.security.gpg = { enable = mkEnableOption "Enable GPG module"; };
config = mkIf cfg.enable {
programs.gpg = {
enable = true;
@ -22,7 +26,12 @@ in
enableSshSupport = true;
enableBashIntegration = true;
enableScDaemon = true;
pinentryPackage = pkgs.pinentry-tty;
pinentryPackage =
if wm.enable then
pkgs.pinentry-gtk2
else
pkgs.pinentry-curses;
};
};
}