Using Multiple Identities with GitHub

When using multiple accounts with GitHub, it may be necessary to commit changes to private repositories which may not accessible by all accounts.

This is how to generate the key and add it to the SSH agent; then add it to the GitHub account too.

ssh-keygen -t RSA -b 2048 \
    -f ~/.ssh/github_aa -C "marco@alertavert.com"
eval "$(ssh-agent -s)"
ssh-add ~/.ssh/github_aa

The original solution was here.

Advertisement

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: