Remove old GnuPG setup, replaced by systemd socket activation
This commit is contained in:
parent
9385ab2f72
commit
e4f2a41e1f
22
.profile
22
.profile
@ -1,25 +1,3 @@
|
||||
#-*- mode: sh; -*-
|
||||
|
||||
source $HOME/.zshenv
|
||||
|
||||
# Gnupg setup
|
||||
if hash gpg-agent 2>/dev/null
|
||||
then
|
||||
# Start the gpg-agent if not already running
|
||||
if ! pgrep -x -u "${USER}" gpg-agent >/dev/null 2>&1; then
|
||||
gpg-connect-agent /bye >/dev/null 2>&1
|
||||
fi
|
||||
|
||||
# Set SSH to use gpg-agent
|
||||
unset SSH_AGENT_PID
|
||||
if [ "${gnupg_SSH_AUTH_SOCK_by:-0}" -ne $$ ]; then
|
||||
export SSH_AUTH_SOCK="/run/user/$UID/gnupg/S.gpg-agent.ssh"
|
||||
fi
|
||||
|
||||
# Set GPG TTY
|
||||
GPG_TTY=$(tty)
|
||||
export GPG_TTY
|
||||
|
||||
# Refresh gpg-agent tty in case user switches into an X session
|
||||
gpg-connect-agent updatestartuptty /bye >/dev/null
|
||||
fi
|
||||
|
Loading…
Reference in New Issue
Block a user