[Scons-dev] Huge merges in Mercurial

Russel Winder russel at winder.org.uk
Thu Dec 24 05:33:43 EST 2015


On Sat, 2015-12-19 at 14:51 +0100, Dirk Bächle wrote:
> 
[…]
> not with Mercurial so far, but here's what I tend to do at work
> (Clearcase) when things get complicated:
> 
> For every conflicting file I'll accept the "new" changes completely,
> overwriting old stuff. This is just to get the basic "merge" 
> operation through.
> Afterwards, I look at the single "diffs" and do the actual merge work
> by trying to amend those places where some of the "old" stuff 
> is still needed.

I think I may go this route. If this were Git or Bazaar I can perform
the full merge and then generate a diff to capture things that got
deleted. Mercurial must have this capability somewhere.

> Note how you can list the "to be resolved" files with
> 
>    hg resolve -la

My difficulty just now is that my set up is to spawn a meld job for
each (3-way) merge conflict resolution. For my normal workflow this
works well as I get maybe two or three files in need of working on, and
few changes to resolve.

For this case, there are 30 or 40 files that have merge conflicts, many
of which are trivial, but some of which need real thought.

I am rapidly coming to the conclusion, that forcing the full set of
default changesets overiding the supposed conflicts and then finding
the problems and reusing the previous solutions at that point is the
way forward.

My reasoning here is that for a couple of the conflicts I saw, the new
changesets were deleting code that the old python3 brnch had changes
in. This is most easily handled by not handling and letting the default
changesets win the conflict battle forcibly.

Also doing this allows me to do "conflict resolution" file by file
individually. The problem I was having earlier was that Mercurial was
driving the use of meld to resolve conflicts automatically and not
completing the merge quickly.

> Hope this helps you further, you may want to combine the "amend" work
> with using the MQ extension...

I think this has been most useful, in that it has made me decisive. The
16 months of changesets will go in forcibly and then I will redo the
python3 updates based on the overwritten changesets. I will not rely on
history in the repository but have two clones one the past, one the
future, then I can run scripts (probably written in D, as I am feeling
perverse :-) comparing the old and new at my leisure.

You have to love DVCS. :-)

-- 
Russel.
=============================================================================
Dr Russel Winder      t: +44 20 7585 2200   voip: sip:russel.winder at ekiga.net
41 Buckmaster Road    m: +44 7770 465 077   xmpp: russel at winder.org.uk
London SW11 1EN, UK   w: www.russel.org.uk  skype: russel_winder

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 181 bytes
Desc: This is a digitally signed message part
URL: <https://pairlist2.pair.net/pipermail/scons-dev/attachments/20151224/9e470eeb/attachment.pgp>


More information about the Scons-dev mailing list