sshgpgagent 428 B

1234567891011121314
  1. #### My (demuredemeanor) sub source gpg-ssh-agent script
  2. # Uses tabstop=4; shiftwidth=4 tabs; foldmarker={{{,}}};
  3. # https://notabug.org/demure/dotfiles/
  4. # legacy repo http://github.com/demure/dotfiles
  5. # vim:set syntax=sh:
  6. ## SSH GPG Agent
  7. function __ssh_gpg_agent() {
  8. unset SSH_AGENT_PID
  9. if [ "${gnupg_SSH_AUTH_SOCK_by:-0}" -ne $$ ]; then
  10. export SSH_AUTH_SOCK="$(gpgconf --list-dirs agent-ssh-socket)"
  11. fi
  12. }