Commits on github are linked to right user while pushes are linked to wrong user

393 views Asked by At

Commits(for new or old branch) done after changing the username and email are linked to me while Pushes(for both old and new branch) are for old user.

Moreover if I setup a new project or anything new as generating ssh keys I get the message in terminal as previous user. How do I remove that previous user from my system so that everything done related to github from my system should be related to my account.

I changed the config file through this link , it is also showing the correct username and email through git config --global user.name or git config --global user.email.

https://help.github.com/articles/setting-your-email-in-git/

1

There are 1 answers

0
royki On BEST ANSWER

Check in the console as

git config --list

It will list all your git configuration status.

then try

git config --global --unset-all user.name

and then

git config --global --add user.name <your_username>

You can try from this link also. See the 1st Answer Hope it might work !!!