Fwd: switch from tag with externals to a trunk without can put wc into inconsistent state
anatoly techtonik <[email protected]>
| Newsgroups | gmane.comp.version-control.subversion.user,gmane.comp.version-control.subversion.rapidsvn.devel |
|---|---|
| Message-ID | <d34314100911160650n242d973fu34d6c0b0fc2248b__3383.7633360692$1258383198$gmane$org@mail.gmail.com> |
Any progress on this one? I want to file a bugreport. Forwarding to users. Please, CC -- anatoly t. ---------- Forwarded message ---------- From: anatoly techtonik <[email protected]> Date: Tue, Nov 10, 2009 at 12:47 AM Subject: switch from tag with externals to a trunk without can put wc into inconsistent state To: Subversion Development <[email protected]> Hello, This is the state of my working copy after I've isolated the bug: $ svn up At revision 2. $ svn st $ ls top sub1 $ svn ls top sub1/ sub2/ It seems bogus and was caused by switching from a tag back to trunk. Tag has top/sub2/ set to point to the same directory in trunk via svn:externals Test script is attached. Looks like svn:externals in this case should be handled before updating files to allow switch to proceed. Is there a bug report for this behaviour or is it something new? svn, version 1.6.4 (r38063) compiled Aug 18 2009, 07:56:06 Debian 5.0 Please, CC. -- anatoly t. ------------------------------------------------------ http://subversion.tigris.org/ds/viewMessage.do?dsForumId=1065&dsMessageId=2418530 To unsubscribe from this discussion, e-mail: [[email protected]].
test_issue_xxx.sh
(application/x-sh, 1.5 KB)
#!/bin/sh
REPOS=issue-XXX-repos
WC=issue-XXX-wc
echo "### Removing old test data ..."
rm -rf ${REPOS} ${WC}
echo "### Creating repository ..."
svnadmin create ${REPOS}
SVNROOT=file://`pwd`/${REPOS}
echo "### Checkout out working copy ..."
svn co ${SVNROOT} ${WC}
cd ${WC}
echo "### Creating some trunk stuff..."
svn mkdir --parents trunk/top/sub1 trunk/top/sub2 tags
touch trunk/top/sub2/file
svn add trunk/top/sub2/file
svn ci -m "Add trunk stuff."
echo "### Making a tag with top/sub2 continued to update from trunk"
svn rm trunk/top/sub2
svn pset svn:externals "top/sub2 ${SVNROOT}/trunk/top/sub2" trunk
svn cp trunk ${SVNROOT}/tags/extag -m "Add tag with trunk external."
svn revert -R trunk
echo "### Switching trunk to the tag ..."
svn switch ^/tags/extag trunk
echo "### Checking URL on trunk/top/sub2 (should be external from trunk) ..."
svn info trunk/top/sub2 | grep URL
echo "### Checking URL on trunk/top/sub1 (should point to tag) ..."
svn info trunk/top/sub1 | grep URL
echo "### Switching back to trunk"
svn switch --force ${SVNROOT}/trunk trunk
echo "### Removing offending trunk/top/sub2"
rm -rf trunk/top/sub2
echo "### Trying to switch back to trunk again"
svn switch --force ${SVNROOT}/trunk trunk
svn st
echo "### Removing trunk/top/sub2 manually"
rm -rf trunk/top/sub2
echo "### Checking state of working copy vs repository"
svn st trunk
svn up trunk
echo "### Local ls of trunk/top"
ls trunk/top
echo "### Repository ls of trunk/top"
svn ls trunk/top