incubator-ooo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stephan Bergmann <stephan.bergmann.second...@googlemail.com>
Subject Re: An svn question
Date Fri, 24 Jun 2011 07:07:53 GMT
On Jun 23, 2011, at 10:55 PM, Herbert Duerr wrote:
>>> PS: I wonder, was there history lost as part of the past move to Hg?  I had the
sense it was preserved, but am now unsure.
>> 
>> History was fully preserved, and full history is very important if you want to work
on the code.
> 
> During both the CVS->SVN and the SVN->HG migration only the trunk got imported
and the evolution on the branches was forgotten. Since all the good branches were merged into
trunk anyway no code was lost, but the history became barely usable, because the work of a
each CWS was merged as one huge patch:
> e.g. http://hg.services.openoffice.org/DEV300/rev/3d0fcd312
> So individual commits and their comments were drowned in that big resulting patch.
> 
> History only got fully preserved in the sense that after the migrations both CVS and
SVN servers were still readable but not in the sense that the conversion result contained
the history.

Right, I almost forgot.  When SVN merges a branch back into trunk, it does not reflect the
detailed history of the branch in the trunk.  As the branch history is still available in
the SVN repository, this is no real data loss, just a loss in usability (for my taste, at
least).

Which gets me thinking of the next topic, how exactly to import the current OOo Hg repository
into SVN.  While Hg has the concept that a revision can have two parents (so the revision
graph need not be linear), SVN only supports a single parent per revision (so has a strictly
linear graph).  Import of Hg into SVN will have to map the non-linear graph to a linear one.
 I think an automatic approach (which is the only feasible one) in general can only work as
follows:  Walking backwards from the head (assuming there is only one), transfer the current
revision to SVN and proceed to its first parent (if there is one; otherwise we reached the
bottom and are done).  Since CWS have (hopefully) always been merged into the master as the
second parent of a merge revision (if a merge was necessary), this will loose the detailed
history of most CWS.  (And if a CWS ever got merged as the first parent of a merge revision,
and master as second, we will loose history big time.)  So from a history-preserving point
of view, moving from Hg to SVN is bad.  Or am I missing something?

-Stephan
Mime
View raw message