After recently taking a programming course online which required us to upload our homework assignments into Github, ever since then whenever I type git push -u origin master
I get:
remote: Permission to my-github-username/mygithubrepo.git denied to rheros.
fatal: unable to access 'https://github.com/my-github-username/mygithubrepo.git/': The requested URL returned error: 403
rheros
is the name of the repository that I used to push my homework assignments to. Obviously, now I'm not using rheros
anymore, yet the command line thinks I'm still trying to push to it. I tried checking whether I have a faulty SSH key, but everything looks fine.
How can I make my command line effectively forget about the existence of a completely irrelevant directory that I pushed to before?
EDIT
git remote --verbose
gives:
origin https://github.com/my-github-username/mygithubrepo.git (fetch)
origin https://github.com/my-github-username/mygithubrepo.git (push)
So far, none of the suggestions below have helped me: it seems that the rheros
repo is running somewhere in the background of my command line, and I can't figure out how to eliminate it.