mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2024-11-19 21:41:07 +01:00
ssh-agent: check ssh-agent process w/ ps again
The alternative is using tools that aren't available everywhere. The latest report is that cygwin/msys2 doesn't have pgrep. Fixes #5418.
This commit is contained in:
parent
5cf9263907
commit
5bd9500bf4
1 changed files with 1 additions and 1 deletions
|
@ -30,7 +30,7 @@ if [[ $_agent_forwarding == "yes" && -n "$SSH_AUTH_SOCK" ]]; then
|
|||
elif [[ -f "$_ssh_env_cache" ]]; then
|
||||
# Source SSH settings, if applicable
|
||||
. $_ssh_env_cache > /dev/null
|
||||
pgrep ssh-agent | grep -q $SSH_AGENT_PID || {
|
||||
ps x | grep ssh-agent | grep -q $SSH_AGENT_PID || {
|
||||
_start_agent
|
||||
}
|
||||
else
|
||||
|
|
Loading…
Reference in a new issue