git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Andrew Sayers <andrew-git@pileofstuff.org>
To: Git Mailing List <git@vger.kernel.org>
Subject: Bug in svn-fe: copying the root directory acts as if it's an empty directory
Date: Wed, 07 Mar 2012 23:13:06 +0000	[thread overview]
Message-ID: <4F57EB82.4000309@pileofstuff.org> (raw)

Here's a bug with svn-fe that I stumbled over while snorkelling through
repo madness.  I've tested it with the version of svn-fe in git.git's
master branch.

Copying the root directory to a sub-directory (e.g. doing `svn cp .
trunk` to standardise your layout) doesn't correctly initialise the new
directory.  To replicate the issue, run the following script from an
empty directory (update GIT_DIR to point to your git.git repository):

GIT_DIR="/home/andrew/git/git"
ROOT_DIR="$(pwd)"

svnadmin create repo
svn checkout "file://$ROOT_DIR/repo" checkout
cd checkout
echo text > README.txt
svn add README.txt
svn ci -m "Created README.txt"
svn cp "file://$ROOT_DIR/repo" "file://$ROOT_DIR/repo/trunk" \
    -m "Created trunk"
cd ..
mkfifo backchannel
mkdir git-repo
cd git-repo/
git init
svnadmin dump --deltas "$ROOT_DIR/repo" \
    | "$GIT_DIR/contrib/svn-fe/svn-fe" 3<../backchannel \
    | "$GIT_DIR/git-fast-import" --cat-blob-fd=3 3>../backchannel

Expected: the git repo contains "README.txt" and "trunk/README.txt"
Observed: "README.txt" exists but "trunk/README.txt" doesn't

	- Andrew

             reply	other threads:[~2012-03-07 23:13 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-03-07 23:13 Andrew Sayers [this message]
2012-03-08  0:46 ` Bug in svn-fe: copying the root directory acts as if it's an empty directory David Barr

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4F57EB82.4000309@pileofstuff.org \
    --to=andrew-git@pileofstuff.org \
    --cc=git@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).