mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2026-01-02 02:19:06 +01:00
Redirect the output of GPG and SSH agent plugins
This commit is contained in:
parent
6ac5c25e77
commit
7a745425c4
2 changed files with 5 additions and 7 deletions
|
|
@ -13,14 +13,14 @@ if (( ! $+commands[gpg-agent] )); then
|
|||
fi
|
||||
|
||||
function _gpg-agent-start() {
|
||||
gpg-agent --daemon --enable-ssh-support --write-env-file "${_gpg_env}"
|
||||
gpg-agent --daemon --enable-ssh-support --write-env-file "${_gpg_env}" > /dev/null
|
||||
chmod 600 "${_gpg_env}"
|
||||
source "${_gpg_env}"
|
||||
source "${_gpg_env}" > /dev/null
|
||||
}
|
||||
|
||||
# Source GPG agent settings, if applicable.
|
||||
if [[ -f "${_gpg_env}" ]]; then
|
||||
source "${_gpg_env}"
|
||||
source "${_gpg_env}" > /dev/null
|
||||
ps -ef | grep "${SSH_AGENT_PID}" | grep -q 'gpg-agent' || {
|
||||
_gpg-agent-start
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue