views:

949

answers:

3

Hello,

I am trying to migrate a part of SVN repository using svnadmin dump.

The provided svndumpfilter tool doesn't manage copy/move/rename dependencies from directories not included in the export.

Is there a tool which can manage these dependencies?

Thanks.

A: 

With dependencies you mean those specified by the property svn:external?

If yes, I think you should pass to svndumpfilter also the paths referrend in the property. For example, if your project is in http://host/project and the svn:external property is set to http://host/dependencies you can do something like

svndumpfilter include http://host/project http://host/dependencies < total.dump > project.dump
Davide Gualano
A: 

You cannot get rid of this problem. if you copied a directory/file, you have to include both(source and destination) into svndumpfilter. However you can do some tricks:

if you dump a repoositry not from revision 0, but say eg. from rev.100, you will get a new repository with revision 1-100 vanished, however your destination repository has all files/folders in rev. 1 as your source repo in revision 100. In this way you can get rid of versioned data without loosing the HEAD-Revision.

You can try to dump/load your source repo until your first copy into a "flat" repo, then add the remaining dumps onto it. In this way you can skip the troublesome copy-from Revision, as your files are already in the fitting (destination) directory.

Peter Parker
+3  A: 

I found a Python script by Simon Tatham called svndumpfilter2, which tries to cope with simple dependencies (I found some limitations, though).

You can also check an article about his migration to Subversion and the motivation for the script.

antispam