1

I'm using someone else's computer, and I cloned my own repository to this computer, and started working on it.
But when I was trying to push it:

$ git push origin master

it says:

remote: Permission to MyNewAccount/Project.git denied to SomeOneElsesAccount.
fatal: unable to access 'https://github.com/MyNewAccount/Project/': The 
requested URL returned error: 403

So basically I just need to change the default user name and user passport, which is now still the other guy's, right? But I don't know how to do it.

VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250

1 Answers1

1

Check the git global config: if you see a credential.helper set to manager, that means the credentials are store in the Windows Credential Store (see Git-Credential-Manager-for-Windows).

To make sure you don't use that credential helper, set it to "" (since Git 2.9) just for your repo

cd c:\path\to\my\repo
git config credential.helper ""

That will prevent the global one to be active, and allow you to enter your username and password.

Community
  • 1
  • 1
VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250