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

Switch a file to a dir: can't switch it back to the file

From: Julian Foad <julianfoad_at_btopenworld.com>
Date: 2003-09-23 00:49:20 CEST

This can't be right. Any ideas? Reproduction script and its output are below; the error is right at the end of the output.

Here is the reproduction script:

~/src/subversion> cat svn-switch-test.sh
#!/bin/bash
# Show the bug in which after switching a file to a dir,
# it cannot be switched back to the file.

set -x -e
mkdir svn-switch-test
cd svn-switch-test
svnadmin create repos
REPOS=file://`pwd`/repos
svn co $REPOS wc
cd wc

# Now we have a repository and a WC, start playing in the WC.
mkdir d; touch f
svn add d f
svn ci -m "New dir and file."
svn switch $REPOS/d f
svn switch $REPOS/f f # bang!

Here is the output:

~/tmp> ~/src/subversion/svn-switch-test.sh
+ mkdir svn-switch-test
+ cd svn-switch-test
+ svnadmin create repos
++ pwd
+ REPOS=file:///home/julianfoad/tmp/svn-switch-test/repos
+ svn co file:///home/julianfoad/tmp/svn-switch-test/repos wc
Checked out revision 0.
+ cd wc
+ mkdir d
+ touch f
+ svn add d f
A d
A f
+ svn ci -m 'New dir and file.'
Adding d
Adding f
Transmitting file data .
Committed revision 1.
+ svn switch file:///home/julianfoad/tmp/svn-switch-test/repos/d f
D f
A f
Updated to revision 1.
+ svn switch file:///home/julianfoad/tmp/svn-switch-test/repos/f f
/home/julianfoad/src/subversion/subversion/libsvn_repos/delta.c:209: (apr_err=160005)
svn: Invalid filesystem path syntax
svn: svn_repos_dir_delta: invalid editor anchoring; at least one of the input paths is not a directory and there was no source entry

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Tue Sep 23 00:49:05 2003

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.