summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorAlan Pearce2017-08-29 14:33:44 +0200
committerAlan Pearce2017-08-29 14:33:44 +0200
commit82485764d3001c5759bb2e56a4e2779633dcc644 (patch)
tree8e000eadbb344fc7c926e3e0cd24f89aea23f5cc
parent51784ea0031ab238e3c9fa6c5e18c12e2ee56225 (diff)
downloaddotfiles-82485764d3001c5759bb2e56a4e2779633dcc644.tar.lz
dotfiles-82485764d3001c5759bb2e56a4e2779633dcc644.tar.zst
dotfiles-82485764d3001c5759bb2e56a4e2779633dcc644.zip
zsh: Don't configure GPG SSH agent on osx
-rw-r--r--zsh/.config/zsh/.zshenv15
1 files changed, 9 insertions, 6 deletions
diff --git a/zsh/.config/zsh/.zshenv b/zsh/.config/zsh/.zshenv
index 797dc62..dc84f1d 100644
--- a/zsh/.config/zsh/.zshenv
+++ b/zsh/.config/zsh/.zshenv
@@ -10,12 +10,6 @@ then
     . $ZDOTDIR/zshenv.private
   fi
 
-  unset SSH_AGENT_PID
-  if [[ "${gnupg_SSH_AUTH_SOCK_by:-0}" -ne $$ ]]
-  then
-    export SSH_AUTH_SOCK="$(gpgconf --list-dirs agent-ssh-socket)"
-  fi
-
   if [[ -e $HOME/.nix-profile/etc/profile.d/nix.sh ]]
   then
     . $HOME/.nix-profile/etc/profile.d/nix.sh;
@@ -47,6 +41,15 @@ then
     fi
   fi
 
+  if [[ $os != "darwin" ]]
+  then
+    unset SSH_AGENT_PID
+    if [[ "${gnupg_SSH_AUTH_SOCK_by:-0}" -ne $$ ]]
+    then
+      export SSH_AUTH_SOCK="$(gpgconf --list-dirs agent-ssh-socket)"
+    fi
+  fi
+
   case $MACHTYPE in
     *64)
       arch=amd64