7 lines
249 B
Bash
7 lines
249 B
Bash
if ! pgrep -u $USER ssh-agent > /dev/null; then
|
|
ssh-agent > ~/.ssh-agent-thing
|
|
fi
|
|
if [[ "$SSH_AGENT_PID" == "" ]]; then
|
|
eval $(<~/.ssh-agent-thing)
|
|
fi
|
|
ssh-add -l >/dev/null || alias ssh='ssh-add -l >/dev/null || ssh-add && unalias ssh; ssh'
|