Last Updated: February 25, 2016
· charlybr

Git: choose your ssh key

create a GITSSH wrapper in your ~/bin/gitsshwrapperdeploy

ssh -i /home/charlybr/.ssh/deploy_id_rsa $1 $2

export this wrapper when logging in

In your .bashrc for example:
export GITSSH="/home/charlybr/bin/gitsshwrapperdeploy"

or you can just export this env variable when you need it

git clone && code monkey

You're done!

2 Responses
Add your response


Or just use ssh-agent(1) and avoid all this juggling?

over 1 year ago ·

But does it work with automated shell scripts that use git ?

over 1 year ago ·