PRODUCTS

We provide our global customers with solutions focused on enabling them to conceive, build and deliver the highest quality software at speed, in the manner and using the methods that best suit their particular requirements.

SOLUTIONS

Our solutions energize digital transformations. Our customers span industries including government, financial, and biotech. We inspire the future by enabling embedded and IoT technologies. We even make software development connect closely to the enterprise with value stream management. Our solutions free organizations to focus on their business challenges.

TRAINING

Learn from the masters. As industry leaders in agile, we invite knowledge seekers interested in learning about agile and scrum certification to train with us. We have courses for students, engineers, project managers, and management. From fundamentals to mastery, our experts will teach you what you need to know to apply your new knowledge successfully in your role.

subversion Discussion topic

Re: svndumpfilter: E200003: Invalid copy source path

Author

cmpilato

Full name

C. Michael Pilato

Date

2014-04-18 11:14:47 PDT

Message

On 04/18/2014 12:48 PM, A H wrote:> Thank you very much for the prompt response Michael.> > The reason I'm looking into this is because we are going to be> bringing some development in house that we previously contracted out> and we would like to bring all of the history over with it. But we> can't take their trunk too because it contains other clients.> > Option 3 seems to be the most promising for this. We don't really> care much about the revision history before we were a client so if we> could take everything from when our branch was created and beyond I> believe that would be fine. Can you tell me how to do a dump starting> at a certain revision?> > My guess would be run "svnadmin dump --incremental 60 E:\svnhome\Repo> > Dump.dmp" and then do my filtering based on that. Will that give me> what I need?> > Also, how does it work if I have spaces in the branch name? Another> project had spaced and using quotes for the filtering didn't seem to> work.

Assuming your branch was created in revision 60, there are a fewdifferent routes you could take here. The simplest is to do this:

svnadmin dump -r60:HEAD E:\svnhome\Repo > Dump.dump

You don't use the --incremental flag, because that tells svnadmin togenerate the first revision of the dump as a delta against the previousrevision in the repository. When you later try to apply that dump to anew repository, Subversion will error out because you're trying to giveit only a delta against (what it sees as) nonexistent history.

But without the --incremental flag, understand that the first revisionof the dumpfile is going to be ginormous -- every single file anddirectory in all branches present in revision 60. Revisions 61 andbeyond will be just the changes made in those revisions, then.

There's another approach that works well so long as the revision inwhich your branch was created (r60 here) contained no changes except thebranch creation as a copy. If that's the case, you can use the--incremental form but start with the revision in which you startedmaking changes to your branch:

svnadmin dump -r61:HEAD --incremental E:\svnhome\Repo > Dump.dump

The catch here is that you'll have to initialize your final targetrepository with a copy of your branch as it appeared when it was createdbefore loading the deltas from the filtered dumpfile atop it.

Either way, spaces in branch names shouldn't be an issue for the filter. You need only quote the paths that you pass to svndumpfilter:

cat Dump.dump | svnadmin include "/branches/My Branch"

Another approach I forgot to recommend before is to setup a user in theoriginal repository that has read permission only to your branch, andthen use that user to create a mirror of the repository using svnsync.svnsync will honor the permissions in your access file, and will simplyomit the stuff that user can't read, leaving you with a repository thathas a bunch of empty revisions but contains all the changes made to yourbranch only.