When I try to merge a feature
branch into master
, I get a merge conflict every now and then.
Now the obvious solution is to just manually resolve the conflict during the merge.
However, with pull-request based workflows (github, gitlab,...), this is somehow sub-optimal, as it puts all the work on the person who is in charge of actually merging the branch, rather than the submitter.
A somewhat useful solution is to merge master
into feature
before submitting a PR, fixing all the conflicts.
however, I have the feeling that this complicates the git history needlessly.
So I wonder, whether there's a (simple) way to prepare the feature
branch so it can be merged cleanly into master
(after the fact that the two branches have diverged significantly).
Ideally the fixup can be done in multiple commits.