Git push using local config not working

Hello I am using git version
I have a global config.
I am working on another project with a git local config (git config --local) but while pushing git is still using global config

Can someone help me please.
Thankds in advance

What command did you use to update you username ?

Just tried and it works fine.

create a new repository and update your username again.

git config newname

Then check on an old global value using repository.

git config --list


I used git config newname
but it’s not working. It seems like git push is using defining in the global config (git config --global …)


I just did it in a repo

After having changed the user name there are 2 entries returned by the config list. Surely the later supercedes the older. The older comes from global config. The newer is the one I added later.


On the local side

On GitHub

I notice that it did not take the new commiter name on the second commit. I guess this is because it gives precedence to email which wasn’t changed yet. GitHub uses the email to determine your activity in the profile. So it could simply ignore commiter name.


Maybe this is what you are facing.