1. 程式人生 > >git push 出現有將error remote: ERROR: committer email address

git push 出現有將error remote: ERROR: committer email address

在給google提code或者自己公司提code的時候,可能會出現這中郵箱不匹配的問題。

git commit之後,進行git push時,發生如下error

remote:
remote: ERROR:  In commit 98e9d43e685f0a2965dc60471b5f0bc88659f073
remote: ERROR:  committer email address SPREADTRUM\[email protected]
remote: ERROR:  does not match your user account.
remote: ERROR:
remote: ERROR:  The following addresses are currently registered:
remote: ERROR:    
[email protected]
remote: ERROR: remote: ERROR: To register an email address, please visit: remote: ERROR: https://android-review.googlesource.com/#/settings/contact


遇到這種錯誤,需要修改config檔案,來達到效果。

vim ~/.gitconfig

把這個檔案裡的[user]修改一下,沒有的新增一下

[color]
    ui = auto
[commit]
    template = /home/local/SPREADTRUM/AAAA/.commit_template
[user]
    name = AAAA
    email = 
[email protected]
[core] editor = vim [http] cookiefile = /home/local/XXXXX/AAAA/.gitcookies​