How to Configure Multiple Git Accounts in a single computer - RealWorld-Yuchen-Yang/Notes GitHub Wiki

Link to the blog: https://code.tutsplus.com/tutorials/quick-tip-how-to-work-with-github-and-multiple-accounts--net-22574


After configuring the ~/.ssh/config file,
you can switch pushing to different remote by doing the following in the root directory of your project

$git remote add origin USER@HOST_NAME:REPO/PROJECT/XXX.git
then you can try
$git push origin master
or what ever git commands to do the testing


Formate of the profiles in the ~/.ssh/config file
#Default GitHub
Host github.com
HostName github.com
User git
IdentityFile ~/.ssh/id_rsa

⚠️ **GitHub.com Fallback** ⚠️