three-way conflict markers
Pierre Asselin
pa at panix.com
Fri Jan 16 03:09:27 UTC 2009
Is there a reason the filemerge tool omits the base file content
in its conflict markers ? The functionality is there in
simplemerge.py:Merge3Text.merge_lines() but no code path uses it.
Seeing the base file content is necessary to resolve some conflicts.
For example,
mine ancestor theirs
----------------------------------------------------
base base base
base base base
base feature A feature A
base base feature B
base base
base
The default merge produces this,
base
base
<<<<<<< .../hg-test/toto/toto
=======
feature A
feature B
>>>>>>> /tmp/toto~other.y-yYyw
base
base
and if I didn't know better I would resolve it by adding
the "A" and "B" lines to "mine". What I need is this,
base
base
<<<<<<< .../hg-test/toto/toto
||||||| /tmp/toto~base.JZas2f
feature A
=======
feature A
feature B
>>>>>>> /tmp/toto~other.I8CN27
base
base
which tells me that I'm deleting A and they added B; resolution is
to keep just B. This sort of thing happens when cherry-picking
(not that I would condone cherry-picking, but sometimes it's useful).
Right now I use "/usr/bin/merge -A" as my merge tool, but
this has disadvantages.
--
pa at panix dot com
More information about the Mercurial
mailing list