2012-10-31 93 views
6

我可以知道終端強制從GIT刪除緩存的命令是什麼?強制刪除緩存

按照我所知道刪除GIT是 的git RM --cached thefilename

但現在我得到一個錯誤

錯誤:「tutorial.h」上演了不同的內容,同時從文件和頭 (使用-f強制去除)

所以,我可以知道我將如何刪除它?

+0

...使用-f強制移除? – SomeKittens

+0

yeap所以我想知道完整的命令.... –

回答

17
git rm --cached -f thefilename 
+0

非常感謝,這對我很有幫助 –