How to Use Multiple Github Accounts With SSH Keys on the Same Machine
There might be a chance that you need to create and use a separate github(or bitbucket) account other than your personal one in your workplace. And Github(Bitbucket or Gitlab will do the same I believe) doesn’t allow to share a ssh key between different accounts for authentication.
That’s the case we are going to figure out below.
First of all, create a new ssh key pair on your machine.
|
|
Next, edit/create the ssh config file.
|
|
|
|
Test the ssh authentication.
|
|
Now you should be able to clone repos in your workplace org.
|
|
You got an idea to do this in a better way? Then you got it!
Happy coding!