![](/img/trans.png)
[英]Git Checkout -f to undo all local changes sets back to initial commit
[英]on git pull asking to commit the local changes
我在做git pull,
它說
錯誤:您對以下文件的本地更改將被合並所覆蓋:Gemfile請先提交更改或將其存儲起來,然后再進行合並。 墮胎
我不記得對gemfile
做任何更改。
在git status
除了我已刪除的所有文件之外,什么都沒有顯示。
我該如何解決。 以及如何在執行git status
時刪除所有顯示的已刪除文件。
請幫忙。
對於這種情況,您必須使用git stash
引用此鏈接( https://git-scm.com/book/no-nb/v1/Git-Tools-Stashing )
gemfile
。 這會將gemfile
恢復到先前的提交。 然后進行合並。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.