Created
June 16, 2011 17:35
-
-
Save git2samus/1029767 to your computer and use it in GitHub Desktop.
ssh-wrapper - for use with https://gist.github.com/1004653 (buildhuman script)
This file contains 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
#!/bin/sh | |
# ssh-wrapper :: helper script for git to run custom ssh commands | |
# | |
# example usage: | |
# GIT_SSH=ssh-wrapper GIT_SSH_KEY=my_private_key.rsa git ... | |
if [ -s "$GIT_SSH_KEY" ]; then | |
exec ssh -i "$GIT_SSH_KEY" "$@" | |
else | |
exec ssh "$@" | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment