修改用户名和邮箱地址:
$ git config --global user.name "谁修改的(name)"
$ git config --global user.name "your email of gitHub/Gitee "
如果用户名或邮箱设置错误,再次使用相同命令设置,如果出错的话,可以尝试以下方式:
使用--replace-all来修改全局初始话的用户名和密码:
修改用户名:
$ git config --global --replace-all user.name "xxxx"
修改邮箱账号
$ git config --global --replace-all user.email "gitHub/Gitee邮箱账号"
可以使用:git config user.name命令来查看修改
$ git config user.name
如果不想每次pull/push时输入用户名和密码,可以使用命令:
$ git config --global credential.helper store