How do I edit email in git?

1

I had put an email as default in the github account, and consequently in the global git config but the problem that I ended the yahoo account and included hotmail as main in the github settings, but, is giving that problem. I searched but did not find any command to edit the email. Anyway, how do I edit the new email in git?

    
asked by anonymous 01.03.2016 / 04:15

1 answer

2

A simple way is to edit the CONFIG file that is inside the .git folder

There you edit the following:

[user]
  name = seu nome vem aqui
  email = aqui vai seu email

There are command-line commands, but this should solve your problem.

Update

This change applies to a specific repository. For a global configuration you can make the same change in the .gitconfig file that is inside your home.

If windows should be c:\User\seu usuário .

If linux should be /home/seu_usuario .

You can still do this via the command line:

git config --global user.name "SEU NOME"
git config --global user.email "SEU EMAIL"

But as I mentioned, the end result will be the same.

    
01.03.2016 / 04:20