X-Git-Url: https://git.sev.monster/~sev/dotfiles.git/blobdiff_plain/03b903de311946827e690f4db8b082c0ab32dc47..8650c486663161fc96e7aa837709971b8a02359d:/base/.zprofile diff --git a/base/.zprofile b/base/.zprofile index 82e70e4..a0e4d36 100644 --- a/base/.zprofile +++ b/base/.zprofile @@ -28,8 +28,10 @@ export PYTHONSTARTUP=~/.pythonrc if (( ${+commands[gpg]} )) { # SSH_AUTH_SOCK should be set in a remote SSH session for passthrough # if it isn't, we are likely the first login shell on the local machine - if [[ ! -v SSH_AUTH_SOCK ]] { + # we also want to update USE_TTY if we are the login shell in graphics mode + if [[ ! -v SSH_AUTH_SOCK || -v DISPLAY ]] { export GPG_TTY=$(tty) + export PINENTRY_USER_DATA=USE_TTY=$((! ${+DISPLAY})) gpg-connect-agent UPDATESTARTUPTTY /bye >/dev/null export SSH_AUTH_SOCK=$(gpgconf --list-dirs agent-ssh-socket) }