Only initialize gpg-agent if it's not an SSH connection or a toolbox
This commit is contained in:
parent
42f1b4c84b
commit
6936cab5c2
|
@ -1,4 +1,6 @@
|
|||
export GPG_TTY="$TTY"
|
||||
export SSH_AUTH_SOCK="$(gpgconf --list-dirs agent-ssh-socket)"
|
||||
gpgconf --launch gpg-agent
|
||||
gpg-connect-agent updatestartuptty /bye &> /dev/null
|
||||
if [[ -z $SSH_CONNECTION ]] && [[ $HOSTNAME != "toolbox" ]]; then
|
||||
export GPG_TTY="$TTY"
|
||||
export SSH_AUTH_SOCK="$(gpgconf --list-dirs agent-ssh-socket)"
|
||||
gpgconf --launch gpg-agent
|
||||
gpg-connect-agent updatestartuptty /bye &> /dev/null
|
||||
fi
|
||||
|
|
Loading…
Reference in a new issue