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

Re: Creating directory copy operations in a dump stream

From: Johan Corveleyn <jcorvel_at_gmail.com>
Date: Fri, 11 Oct 2019 11:47:56 +0200

On Fri, Oct 11, 2019 at 11:41 AM Eric S. Raymond <esr_at_thyrsus.com> wrote:
>
> After years of eyeballing Subversion dump streams as part of making
> reposurgeon work, I have belatedly realized there is a dump stream
> operation I don't know how to generate with the CLI. And I need to
> to get good test load coverage.
>
> If, in a normally-set up Subversion repository, I create and commit
> three files under trunk and then do "svn copy trunk branches/stable",
> what I see being generated into the dump is three file copies to
> stable.
>
> That's fine, but I also want to be able to generate a *directory* copy.
> I see these in the dump files I get in bug reports. Here's an
> example:
>
> Node-path: tags/1.0rc1
> Node-kind: dir
> Node-action: add
> Node-copyfrom-rev: 5
> Node-copyfrom-path: tags/1.0
>
> How do I generate this kind of operation from the CLI - that is, a copy of the
> whole directory rather than a wildcarded copy of all of its files?

I'd try two things:

- Just guessing here, but perhaps the problem with your test is that
your working copy is "mixed-revision" after you added the three files.
I.e. the 'trunk' directory is a revision behind, after you added the
three files. See if it makes a difference if you do "svn up $wc_root"
before performing the "svn copy trunk branches/stable".

- Maybe you can get what you want by performing a server-side copy,
instead of in your working copy and then committing. I.e. "svn copy
$url/trunk $url/branches/stable".

-- 
Johan
Received on 2019-10-11 11:48:17 CEST

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

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