2

I found the solution for problem when I tried cloning my project its shows wrong user/password, but upon trying to unset credentials using command:

git config --system --unset credential.helper

the error exist as:

Could not lock config file C:\Program Files\Git\mingw64/etc/gitconfig:Permission denied
Could not lock config file C:\Program Files\Git\mingw64/etc/gitconfig:Invalid argument
VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250

2 Answers2

1

Similar to this comment ,try and restart "C:\Program Files\Git\git-bash.exe" as administrator.

That should allow you to modify the system git config file.

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

Though it is late, this may help someone.

In my case, admin privileges were NOT available, but luckily, restart of the IDE (intellIj) prompted for git password again.