Created
February 4, 2014 13:43
-
-
Save jbonney/8803777 to your computer and use it in GitHub Desktop.
Run ssh-agent when you login, and kill it when you logout. Add code to ~/.bash_profile. Taken from http://blog.xk72.com/post/75565726956/ssh-agent
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
eval `/usr/bin/ssh-agent -s` | |
trap "kill $SSH_AGENT_PID" 0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Thanks! Even eight years later such a comment can be helpful! I was looking for the trap part :) 👍