This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function findagent { | |
if ssh-add -l; then | |
echo "Your SSH Agent is already working." | |
return 0 | |
fi | |
for sock in `ls /tmp/ssh-*/agent.*`; do | |
export SSH_AUTH_SOCK=$sock | |
if ssh-add -l; then | |
echo "Your SSH Agent is fixed. New socket=$sock." | |
return 0 |
NewerOlder