2013-04-30 127 views
0

我犯了一個可怕的錯誤。回顧一下我的git提交,似乎我設法得到了一些不正確的數據。更改Git提交信息

我的git提交,而不是看起來像這樣username<[email protected]>看起來像username<mypassword>。我如何解決這個未來的提交?我將取消密碼,但在繼續推送此消息方面似乎不太合適。

我的git電子郵件設置爲我的電子郵件地址,它們未設置爲密碼。有人有主意嗎?

+1

你可以使用'git filter-branch'來重寫歷史記錄,參見[this SO answer](http://stackoverflow.com/a/870367/50552) – Andomar 2013-04-30 18:50:23

回答

1

我懷疑你有一個糟糕的git配置。試試運行:

git config user.name 
git config user.email 

或者找.gitconfig 要看看那裏的東西。你可以覆蓋

git config --global user.email "[email protected]"