最近我执行了git stash
,然后在分支上进行了一些工作并提交了它,在尝试执行git stash apply
时出现了这些错误:
CONFLICT (delete/modify): app/controllers/orders_controller.rb deleted in Updated upstream and modified in Stashed changes. Version Stashed changes of app/controllers/orders_controller.rb left in tree.
CONFLICT (content): Merge conflict in app/models/product.rb
git status
显示如下内容:
$ git status
# On branch develop
# Your branch is ahead of 'origin/develop' by 16 commits.
# Unmerged paths:
# (use "git reset HEAD <file>..." to unstage)
# (use "git add/rm <file>..." as appropriate to mark resolution)
#
# deleted by us: app/controllers/orders_controller.rb
# both modified: app/models/product.rb
“delete/modify”标记的文件是我在执行stash
前新增的文件,还没有提交。
我想回到git stash
命令之前的状态,也就是我的本地修改还没有被提交。请问你有没有办法可以实现这个目标?
谢谢。