问题
I have the following open review in Gerrit:
Change I37783be4
depends on Change Iff96ca11 (MERGED)
Change I37783be4 it's depending on an already merged commit, so I would expect that Gerrit knows how to merge it into master. Still I do get the following error:
Your change requires a recursive merge to resolve. Please merge (or rebase) the change locally and upload the resolution for review.
I tried to fetch that specific changeId and do a 'git rebase master', but the only thing I get back is a sad "Nothing to do" message.
Any ideas of what I'm doing wrong?
回答1:
The problem is the recursive merge strategy. This strategy could be necessary due to file renames etc. Gerrit however uses JGit as Git implementation, and JGit only supports the resolve merge strategy (at least at the moment). So you have to do it locally (and there you may want to use Git and not EGit, since EGit also uses JGit).
You could also try "git rebase origin/master" in case that your local master and your origin/master differ from each other.
回答2:
Strange. Basically you just need to fetch, rebase or merge and then push.
Try git pull --rebase
.
来源:https://stackoverflow.com/questions/10928365/how-to-solve-gerrits-your-change-requires-a-recursive-merge-to-resolve