I\'m working with several repositories, but lately I was just working in our internal one and all was great.
Today I had to commit and push code into other one, but
For macOS users :
This error appears when you are using multiple Git accounts on the same machine.
Please follow below steps to remove the github.com credentials.
- Go to Finder
- Go to Applications
- Go to Utilities Folder
- Open Keychain Access
- Select the github.com and Right click on it
Delete "github.com"
Try again to Push or Pull to git and it will ask for the credentials. Enter valid credentials for repository account. Done