nixos/home/pass/default.nix
Evie Litherland-Smith 22929fa5d8 Add gpg and password-store to Monarch
Only set git credential.helper if using password-store
2023-08-31 08:21:21 +01:00

26 lines
590 B
Nix

{ pkgs, ... }:
{
programs = {
gpg.enable = true;
password-store = {
enable = true;
package = pkgs.pass.withExtensions (exts: [ exts.pass-otp ]);
settings.PASSWORD_STORE_DIR = "$HOME/.password-store";
};
git.extraConfig.credential.helper =
"${pkgs.gitFull}/bin/git-credential-libsecret";
};
services.gpg-agent = {
enable = true;
defaultCacheTtl = 7200;
defaultCacheTtlSsh = 7200;
pinentryFlavor = "gtk2";
extraConfig = ''
no-allow-external-cache
allow-emacs-pinentry
allow-loopback-pinentry
'';
};
}