15 lines
437 B
Bash
15 lines
437 B
Bash
########################################################################
|
|
# GNUPG AGENT
|
|
########################################################################
|
|
|
|
if [ -z $GPG_AGENT_INFO ]
|
|
then
|
|
GPG_TTY=$(tty)
|
|
SSH_AUTH_SOCK=$(gpgconf --list-dirs agent-ssh-socket)
|
|
SSH_AUTH_SOCK_EXTRA=${SSH_AUTH_SOCK%%.ssh}.extra
|
|
export GPG_TTY SSH_AUTH_SOCK SSH_AUTH_SOCK_EXTRA
|
|
pgrep -qu sdk gpg-agent || gpg-connect-agent -q /bye
|
|
fi
|
|
|
|
|