From 23a14b66ba90c05c24385ad394bf6af49f118a40 Mon Sep 17 00:00:00 2001 From: Quentin Duchemin Date: Wed, 1 Nov 2023 18:41:46 +0100 Subject: [PATCH] Ensure GPG keygrips used as SSH keys are correctly read --- .gnupg/sshcontrol | 1 + .zshrc | 6 +----- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/.gnupg/sshcontrol b/.gnupg/sshcontrol index b137079..5faff50 100644 --- a/.gnupg/sshcontrol +++ b/.gnupg/sshcontrol @@ -1,2 +1,3 @@ 8870E499C64EEB7720EBA5A442F4FE90129BFAE3 +# End of file diff --git a/.zshrc b/.zshrc index dfbfd1e..d8cfddc 100644 --- a/.zshrc +++ b/.zshrc @@ -83,13 +83,9 @@ unset SSH_AGENT_PID if [ "${gnupg_SSH_AUTH_SOCK_by:-0}" -ne $$ ]; then export SSH_AUTH_SOCK="$(gpgconf --list-dirs agent-ssh-socket)" fi -export GPG_TTY=$(tty) +export GPG_TTY="$(tty)" gpg-connect-agent updatestartuptty /bye >/dev/null -export KEYGRIP=8870E499C64EEB7720EBA5A442F4FE90129BFAE3 -# Sometimes gpg has a bug and needs to re-import key -alias gbye='gpg-connect-agent "delete_key $KEYGRIP" /bye' - if [ -f ~/.aliases ]; then . ~/.aliases fi