Git merge: accept theirs for multiple conflicts

2019-03-08 17:28发布

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条回答
迷人小祖宗
2楼-- · 2019-03-08 18:07

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
查看更多
登录 后发表回答