I had a git account from my university that I used with my git repositories for my university projects, but now want to to push and pull to my own personal git repositories with my own personal git account (not my university account).
I always get the following error when I try to push or pull from my own repositories:
remote: Permission to repositoryName.git denied to university-username. fatal: unable to access 'https://github.com/respositoryName.git/': The requested URL returned error: 403
I am using Linux Mint and have tried the following with no success:
- Uninstalling and purging all files related to git, then reinstalling and trying to push to my repository.
- Tried to follow the steps from this post: Remove credentials from Git, but cannot seem to get it working as I am running on Linux.
- Tried using
git credential filland entering the username and password and other details I want to use. - Tried setting my new username and email with
git config --global user.name newUsernameandgit config --global user.email newEmail
I am stumped as to what I need to do to completely remove my old credentials and replace them with my new ones.