Eval ssh-agent directly
This commit is contained in:
10
zsh/zprofile
10
zsh/zprofile
@@ -39,14 +39,8 @@ if ! pgrep -x --uid "${USER}" gpg-agent >/dev/null 2>&1; then
|
||||
eval $(gpg-agent --daemon --sh)
|
||||
fi
|
||||
|
||||
# Set SSH to use gpg-agent
|
||||
unset SSH_AGENT_PID
|
||||
if [ "${gnupg_SSH_AUTH_SOCK_by:-0}" -ne $$ ]; then
|
||||
export SSH_AUTH_SOCK="$(gpgconf --list-dirs agent-ssh-socket)"
|
||||
fi
|
||||
|
||||
# Set GPG TTY
|
||||
export GPG_TTY=$(tty)
|
||||
# because gpg-agent is somehow broken for ssh, use the usual ssh-agent
|
||||
eval $(ssh-agent -s)
|
||||
|
||||
# exec startx breaks some logind fuckery, without exec it works
|
||||
if [[ -z $DISPLAY ]] ; then
|
||||
|
||||
Reference in New Issue
Block a user