'how to delete user.name and user.email that empty in git

I entered the wrong user.name and user.email. and now git config -l looks like this: enter image description here

i've try git config --global --unset user. email and git config --global --unset user. name but it wont dissaper. how to fix this?

git


Solution 1:[1]

That config is set in your current repository, not globally. As such, you should not use --global when unsetting. Additionally, since you have them set multiple times, you'll have to use --unset-all:

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

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Leonardo Dagnino