From 61df900e57c7250084be7f76c855cf1e565eb085 Mon Sep 17 00:00:00 2001 From: emerson Date: Mon, 9 Nov 2020 15:08:10 +0000 Subject: [PATCH] only check our processes for ssh-agent --- .zshrc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.zshrc b/.zshrc index f413f7b..3cb37dc 100644 --- a/.zshrc +++ b/.zshrc @@ -67,7 +67,7 @@ alias senv="source .env/bin/activate" if [ -z "$SSH_AUTH_SOCK" ] then # Check for a currently running instance of the agent - RUNNING_AGENT="`ps -ax | grep 'ssh-agent -s' | grep -v grep | wc -l | tr -d '[:space:]'`" + RUNNING_AGENT="`ps -x | grep 'ssh-agent -s' | grep -v grep | wc -l | tr -d '[:space:]'`" if [ "$RUNNING_AGENT" = "0" ] then # Launch a new instance of the agent