Advertisement
Snuggledash

Load ssh-agent on demand

May 7th, 2014
295
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 0.13 KB | None | 0 0
  1. ssh-add() {
  2.         if ! [ -S "$SSH_AUTH_SOCK" ]; then
  3.                 eval $(ssh-agent -s)
  4.         fi
  5.         command ssh-add $*
  6. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement