From dev-return-39541-archive-asf-public=cust-asf.ponee.io@subversion.apache.org Fri Oct 11 10:26:00 2019 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [207.244.88.153]) by mx-eu-01.ponee.io (Postfix) with SMTP id C0C2A180656 for ; Fri, 11 Oct 2019 12:25:59 +0200 (CEST) Received: (qmail 58169 invoked by uid 500); 11 Oct 2019 10:25:59 -0000 Mailing-List: contact dev-help@subversion.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Delivered-To: mailing list dev@subversion.apache.org Received: (qmail 58158 invoked by uid 99); 11 Oct 2019 10:25:58 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 11 Oct 2019 10:25:58 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd4-us-west.apache.org (ASF Mail Server at spamd4-us-west.apache.org) with ESMTP id 2A572C2D5C for ; Fri, 11 Oct 2019 10:25:58 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 0.799 X-Spam-Level: X-Spam-Status: No, score=0.799 tagged_above=-999 required=6.31 tests=[KAM_ASCII_DIVIDERS=0.8, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=disabled Received: from mx1-he-de.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id VnpM5CfLAWJ4 for ; Fri, 11 Oct 2019 10:25:54 +0000 (UTC) Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=71.162.243.5; helo=snark.thyrsus.com; envelope-from=esr@thyrsus.com; receiver= Received: from snark.thyrsus.com (thyrsus.com [71.162.243.5]) by mx1-he-de.apache.org (ASF Mail Server at mx1-he-de.apache.org) with ESMTP id 06EEC7F52C for ; Fri, 11 Oct 2019 10:19:42 +0000 (UTC) Received: by snark.thyrsus.com (Postfix, from userid 1000) id F1B574704893; Fri, 11 Oct 2019 06:19:41 -0400 (EDT) Date: Fri, 11 Oct 2019 06:19:41 -0400 From: "Eric S. Raymond" To: Johan Corveleyn Cc: Subversion Development Subject: Re: Creating directory copy operations in a dump stream Message-ID: <20191011101941.GA22087@thyrsus.com> Reply-To: esr@thyrsus.com References: <20191011094101.474BD4704893@snark.thyrsus.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Organization: Eric Conspiracy Secret Labs X-Eric-Conspiracy: There is no conspiracy User-Agent: Mutt/1.10.1 (2018-07-13) Johan Corveleyn : > - 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". That did the trick, thanks. For your entertainment, here's how the test koad generator now looks: ---------------------------------------------------------------------------- ## General test load for ancestry-chasing logic dump=no verbose=null while getopts dv opt do case $opt in d) dump=yes;; v) verbose=stdout;; esac done trap 'rm -fr test-repo test-checkout' 0 1 2 15 svnaction () { filename=$1 content=$2 comment=$3 if [ ! -f $filename ] then if [ ! -d `dirname $filename` ] then mkdir `dirname $filename` svn add `dirname $filename` fi echo "$content" >$filename svn add $filename else echo "$content" >$filename fi svn commit -m "$comment" $filename } { set -e make svn-branchy cd test-checkout # Content operations start here svnaction "trunk/foo.txt" "Now is the time." "More example content" svnaction "trunk/bar.txt" "For all good men." "Example content in different file" svnaction "trunk/baz.txt" "to come to the aid of their country." "And in yet another file" svn up # Without this, the next copy does file copies. With it, a directory copy. svn copy trunk branches/stable svn commit -m "First directory copy" svnaction "trunk/foo.txt" "Whether tis nobler in the mind." "Hamlet the Dane said this" svnaction "trunk/bar.txt" "or to take arms against a sea of troubles" "He continued" svnaction "trunk/baz.txt" "and by opposing end them" "The build-up" svnaction "trunk/foo.txt" "to be," "Famous soliloquy begins" svnaction "branches/foo.txt" "or not to be." "And continues" svn up svn copy trunk tags/1.0 svn commit -m "First tag copy" # We're done cd .. } >/dev/$verbose 2>&1 if [ "$dump" = yes ] then svnadmin dump -q test-repo fi ---------------------------------------------------------------------------- This will get longer and include the most perverse combinations of deletes and copies I can dream up. The point, of course, is to torture-test my Subversion dump analyzer. I have a fairly nice gallmaufry of static stream dumps I've gathered or made by hand over the years; being able to generate them easily will be helpful. -- Eric S. Raymond