For merging I use this to “keep mine”
git merge -X ours foo
and this for “keep theirs”
git merge -X theirs foo
However on my latest merge it looks best to keep both sides. Does Git have a “strategy” for this, to avoid manually editing the file?
There is no ‘merge strategy’ for resolving these conflicts.
However, if you truly want a conflict like:
to resolve to
then you can configure the ‘merge driver’. From the gitattributes man page:
Add a line to .gitattributes to use this: