-
-
Save jodell/829688 to your computer and use it in GitHub Desktop.
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
# Automagic agent forwarding in remote screen sessions | |
# | |
# From http://superuser.com/questions/180148/how-do-you-get-screen-to-automatically-connect-to-the-current-ssh-agent-when-re-a | |
# In ~/.ssh/rc | |
#!/bin/bash | |
if test "$SSH_AUTH_SOCK" ; then | |
ln -sfv $SSH_AUTH_SOCK ~/.ssh/ssh_auth_sock | |
fi | |
## In ~/.screenrc | |
setenv SSH_AUTH_SOCK $HOME/.ssh/ssh_auth_sock |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment