mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2026-05-29 04:53:17 +02:00
Fix gpg-agent plugin for environments not using XDG_RUNTIME_DIR
This commit is contained in:
parent
e273cf004e
commit
009b78b1aa
1 changed files with 3 additions and 1 deletions
|
|
@ -1,5 +1,7 @@
|
|||
#Define GPG_AGENT_SOCKET
|
||||
GPG_AGENT_SOCKET=`gpgconf --list-dirs agent-ssh-socket`
|
||||
|
||||
# Enable gpg-agent if it is not running
|
||||
GPG_AGENT_SOCKET="${XDG_RUNTIME_DIR}/gnupg/S.gpg-agent.ssh"
|
||||
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