aboutsummaryrefslogtreecommitdiff
path: root/snowfall/modules/home
diff options
context:
space:
mode:
Diffstat (limited to 'snowfall/modules/home')
-rw-r--r--snowfall/modules/home/tools/gpg/default.nix12
1 files changed, 12 insertions, 0 deletions
diff --git a/snowfall/modules/home/tools/gpg/default.nix b/snowfall/modules/home/tools/gpg/default.nix
index 7d69137..297d9d0 100644
--- a/snowfall/modules/home/tools/gpg/default.nix
+++ b/snowfall/modules/home/tools/gpg/default.nix
@@ -16,5 +16,17 @@ in {
};
programs.gpg.enable = true;
+
+ services.gpg-agent = {
+ enable = true;
+ enableSshSupport = true;
+ pinentryPackage = (pkgs.writeShellScriptBin "pinentry-wrapper" ''
+ if [[ -v DISPLAY ]]; then
+ exec ${pkgs.pinentry-gnome3}/bin/pinentry-gnome3 "$@"
+ fi
+
+ exec ${pkgs.pinentry-gnome3}/bin/pinentry-tty "$@"
+ '');
+ };
};
}