Git merge: accept theirs for multiple conflicts

こ雲淡風輕ζ 提交于 2019-12-31 08:32:55

问题


I'm trying to merge a git branch (test-development) back into master. There are lots of merge conflicts but I want as many as possible to be resolved via --theirs. Is there a way to tell git to merge with --theirs in bulk?


回答1:


This will do it if you're mid-merge:

git merge test-development
# Automatic merge failed, a bunch of conflicts!
git checkout --theirs ./path
git add ./path
git commit


来源:https://stackoverflow.com/questions/22544305/git-merge-accept-theirs-for-multiple-conflicts

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!