[cvsnt] Re: Branch merging - this seems wrong...

Andreas Krey a.krey at gmx.de
Wed Jun 7 12:08:16 BST 2006


Community technical support mailing list was retired 2010 and replaced with a professional technical support team. For assistance please contact: Pre-sales Technical support via email to sales@march-hare.com.


On Wed, 07 Jun 2006 11:23:54 +0000, Tony Hoyle wrote:
> Tony Eva wrote:
> >No - the changes in B1 are not lost.  B2 is not just a copy of A3, it is
> >a merged sum of B1 and A3.
>
> No it isn't.  B2 is simply the changes required to go from B1 to the merged
> B1+A3.  Similarly B3 does not contain B2.

Somehow I should really have used revision numbers instead of An and Bn
to make absolutely clear that these are committed revisions, not some
diffs.

B2 ist the *result* of the merge of B1 and A3, thus all changes
on the way A1->(B0)->B1 *and* all changes on the way A1->A2->A3
are present in the revision B2, plus what was needed to resolve
conflicts.

> It does not contain B1. 

No, but B2 as well as B3 contain the changes that were made
from A1 (via B0) to B1.

> No revision ever contains a copy of its ancestors

'course not, except metaphorically.

> You declare it to be equivalent to A3 in the mergepoint,

No. The mergepoint declares that B2 is the result of the
merge of A3 and B1. A3 and B2 differ by everything that
has been done on the branch before, they are *not* equivalent
or the same. Incidentally, the diff bet A3 and B2 is the same
as the diff between A and B1, modulo conflict resolution.

Strictly, the mergepoint/arrow does not record the full story, though.
You as well as the merge arrow (plus the straight arrow) only tell
that B2 is the merged B1+A3, but it doesn't tell what the baseline
version for the merge was.

For reference:

    A
    |
    A1------>B0    # Set branch B on version A1 (B0 is the same as A1)
    |        |
    A2       |
    |        B1    # Independent work
    A3       |
    |        |
    *------->B2    # Merge A up to A3 into B (and commit)
    |        |
    A4       B3    # More independent work

Andreas

-- 
np: 4'33



More information about the cvsnt mailing list
Download the latest CVSNT, TortosieCVS, WinCVS etc. for Windows 8 etc.
@CVSNT on Twitter   CVSNT on Facebook