summaryrefslogtreecommitdiffstatshomepage
path: root/gnupg/.config/profile.d/20-ssh.sh
diff options
context:
space:
mode:
Diffstat (limited to 'gnupg/.config/profile.d/20-ssh.sh')
-rw-r--r--gnupg/.config/profile.d/20-ssh.sh7
1 files changed, 7 insertions, 0 deletions
diff --git a/gnupg/.config/profile.d/20-ssh.sh b/gnupg/.config/profile.d/20-ssh.sh
new file mode 100644
index 0000000..6571e6d
--- /dev/null
+++ b/gnupg/.config/profile.d/20-ssh.sh
@@ -0,0 +1,7 @@
+#!/bin/sh
+
+unset SSH_AGENT_PID
+if [ "${gnupg_SSH_AUTH_SOCK_by:-0}" -ne $$ ]; then
+ SSH_AUTH_SOCK="$(gpgconf --list-dirs agent-ssh-socket)"
+ export SSH_AUTH_SOCK
+fi