Skip to content

Instantly share code, notes, and snippets.

@xdire
Created June 10, 2019 23:52
Show Gist options
  • Select an option

  • Save xdire/76fd8a45e6a57cf71f027202eff8864d to your computer and use it in GitHub Desktop.

Select an option

Save xdire/76fd8a45e6a57cf71f027202eff8864d to your computer and use it in GitHub Desktop.
Git push with a different SSH key for cases when someone uses multiple accounts
// Use SSH Agent command evaluator
ssh-agent sh -c \
'ssh-add ~/.ssh/id_rsa_other;\
git push --set-upstream origin proper_branch_name'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment