我正在與我的同事一起工作feature-branch
。我已經有幾天了,我有committed
我的變化。如何在git pull之後回到之前的未配置狀態
昨天,他一直致力於他的變化和,改變了我們工作,但沒有傷害我的變化,項目的結構。
我已經退出這些變化並提出與mine.Upon測試提交後,我意識到它不工作,我希望它的樣子,所以我想回去的狀態拉之前。
我不能回到我以前的,因爲這樣做,我的最新更改將丟失提交。
我試圖git reflog
這顯示此輸出:
08aed28 [email protected]{0}: commit: Added support for database
4cf0fe8 [email protected]{1}: pull: Fast-forward
d5e2930 [email protected]{2}: commit: Added logs
我做git reset --hard [email protected]{1}
但不會帶我到以前的狀態。
我該怎麼辦?
你可以回到你的老犯,最好創建一個分支,而[摘櫻桃(http://git-scm.com/docs/git-cherry-pick)您的「新」提交到新科。 – 2014-12-03 06:07:52