Use the "union" merge driver for changelogs#5283
Conversation
f5aa91f to
2823e79
Compare
teodanciu
left a comment
There was a problem hiding this comment.
I assume this will result in fewer merge conflicts, nice!
Are there other implications? If we do get merge conflicts, is there anything that we should be aware of, that we need to do different compared to what we've been doing so far?
It's possible the merged result could have the lines in a strange order, although my experiments so far haven't shown any problems other than the one I mentioned in the description.
I don't think conflicts happen at all with this driver, but we should check the merge result carefully, at least until we have more experience with using this. |
2823e79 to
1584f17
Compare
lehins
left a comment
There was a problem hiding this comment.
We should watch out carefully in the near future whether we can spot any issues with this strategy.
If it does work out fine, then it will be indeed a very nice improvement in our workflow, since chnagelogs is the most common source of git conflicts
1584f17 to
4ae84de
Compare
Description
Avoid merge conflicts in changelog files by setting a custom merge driver for them in
.gitattributes.The
uniondriver is built intogitso there's no need to add any settings to.git/config.Unfortunately, the changes from the merged or rebased branch are inserted below the changes from the main branch, but that seems like an acceptable price to pay for a simple configuration that doesn't involve any per-developer setup.
Checklist
CHANGELOG.mdfiles updated for packages with externally visible changes.NOTE: New section is never added with the code changes. (See RELEASING.md).
.cabalandCHANGELOG.mdfiles when necessary, according to theversioning process.
.cabalfiles updated when necessary.NOTE: If bounds change in a cabal file, that package itself must have a version increase. (See RELEASING.md).
scripts/fourmolize.sh).scripts/cabal-format.sh).scripts/gen-cddl.sh)hie.yamlupdated (usescripts/gen-hie.sh).