how remerge works and when to use it?
Alexander Belchenko
bialix at ukr.net
Wed Aug 5 18:41:41 BST 2009
John Arbash Meinel пишет:
> Martin Pool wrote:
>>>> What is reprocess actually and
>>>> for which merge algorithms it is applicable?
>>> What a great question. It reduces the number of conflicts, at some
>>> risk that it won't conflict on things were it should. I'd have to
>>> check the code...
>> OK, so essentially (and I may be wrong) it means that if there are
>> common lines between the two alternatives in a conflict region, the
>> two sides are taken to assume on those lines and the region is split
>> in two.
>
>> It's set by supports_reprocess which is true for merge3 and weave, and
>> by inheritance for LCAMerger and Diff3Merger. Therefore apparently
>> for everything(?) but maybe not external merges?
>
>
> To be technical:
>
> 1) merge algorithms generate regions that conflict
> 2) basic 3-way merge generates these by doing a diff of THIS versus
> BASE and OTHER vs BASE and then notes which regions overlapped.
> 3) Often these regions are strictly larger than they have to be.
> Either because THIS and OTHER actually share some more history, or
> two people did similar edits, etc.
> 4) reprocess grabs the conflicting regions and performs a 2-way diff
> on them. For sub-regions that match, reprocess removes them from
> the conflict.
OK, I've got the picture.
I'm still wonder "when I need/should/could use remerge"? What's benefits?
Does it:
1) remerge intended to use with many many conflicts in the file(s) in the hope it will reduce number
of conflicts?
2) or when criss-cross merge is encountered?
3) or every time when conflicts are produced?
4) or only when user has enough free time to play with remerge instead of actually trying to solve
the conflicts by hands?
I'm just curious and I'm writing new article about merge and conflicts in bzr, so any additional
hints on this command is much appreciated.
Maybe the author(s) of this command can provide some historical info about why for it was created?
What was motivation?
Thanks.
More information about the bazaar
mailing list