[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: Copying a part of another repository, *with* its history

From: Ryan Schmidt <subversion-2008b_at_ryandesign.com>
Date: Wed, 7 May 2008 03:54:22 -0500

On May 6, 2008, at 2:45 PM, Stephane Bortzmeyer wrote:

> On Tue, May 06, 2008 at 09:04:11AM -0700,
> Kevin Grover <kevin_at_kevingrover.net> wrote
> a message of 158 lines which said:
>> The tough points are:
>> 1) You may have to edit the dump file to get the paths to be what
>> you want
>> in the destination repository
> In my case, it was apparently not necessary. If it had been, I would
> have used sed to edit "Node-path" lines in the dump.

Editing a dumpfile by hand (or with sed) can be tricky to get right.
You may be able to use svndumptool to edit the dumpfile more safely.


>> 2) You have to be careful about which directories exist and which
>> need to be
>> created
> That was the trick *and* I needed to commit as well, not just to
> create the directories in a working copy as I did once :-(

Correct, the directory into which you want to load the dump must
already exist in the repository.

>> To prevent accidentally editing the 'old' source, you should 'svn
>> delete'
>> the path from the source repository after successfully migrating it.
> Right.
>> Tools: svndumpfilter (comes with CLI svn install), svn_load_dir.pl
>> (and
>> there's also a newer re-implementation in python, call svnload.py
>> (I think).
> I used only regular "svnadmin load". svn_load_dir.pl seems to be for a
> different use.

Correct, svn_load_dirs.pl is not relevant to this problem.

> Many thanks for the help, I do some more tests and I'll try with my
> real repository soon.
> Some warnings: the revision numbers are not preserved (obviously), the
> dates are, but, now, in the new repository, the order of revisions is
> no longer the chronological order.

Correct, the revisions are no longer chronological with this
approach. If you want to merge two or more repositories and maintain
the chronological property of revisions (i.e. interleave and renumber
the revisions of both repositories) there exist scripts which will do
that. svndumptool will do this, and I think there are other scripts
as well.

To unsubscribe, e-mail: users-unsubscribe_at_subversion.tigris.org
For additional commands, e-mail: users-help_at_subversion.tigris.org
Received on 2008-05-07 10:54:56 CEST

This is an archived mail posted to the Subversion Users mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.