mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2026-05-22 04:51:12 +02:00
Fix MacOS compatibility of the gpg-agent plugin
MacOS holds the GPG agent socket in a different directory than Linux-based systems. Asking gpgconf for the correct path is the most straightforward approach to fix this problem.
This commit is contained in:
parent
c3b072eace
commit
504c32fa6e
1 changed files with 1 additions and 1 deletions
|
|
@ -1,5 +1,5 @@
|
|||
# Enable gpg-agent if it is not running
|
||||
GPG_AGENT_SOCKET="${XDG_RUNTIME_DIR}/gnupg/S.gpg-agent.ssh"
|
||||
GPG_AGENT_SOCKET="$(gpgconf --list-dirs agent-ssh-socket)"
|
||||
if [ ! -S $GPG_AGENT_SOCKET ]; then
|
||||
gpg-agent --daemon >/dev/null 2>&1
|
||||
export GPG_TTY=$(tty)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue