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

Merging a file-turned-symlink fails, and wedges working copy

From: Avi Kivity <avi_at_argo.co.il>
Date: 2006-03-23 12:21:27 CET

If a remove a file, commit, re-create it as a symlink, commit, and merge
the whole thing into a branch, svn will refuse to commit. Moreover, the
working copy will be in an inconsistent state.

The following script reproduces the bug:

#!/bin/sh -ex

svnadmin create merge-bug-repo
repo="file://$PWD/merge-bug-repo"
svn mkdir "$repo/trunk" -m 'create directory tree'
svn mkdir "$repo/branches" -m 'create directory tree'
svn co "$repo/trunk" merge-bug-wc
cd merge-bug-wc
echo 'file content' > file
svn add file
svn ci -m 'added file as a regular file'
svn cp "$repo/trunk" "$repo/branches/branch" \
    -m 'branched while file is still regular'
svn update
branchrev=$(svn info | grep ^Revision | awk ' { print $2 } ')
svn rm file
svn ci -m 'removed file in preparation of replacement with symlink'
echo blah > target
ln -s target file
svn add target file
svn ci -m 're-added file as a symlink (and its target too)'
svn switch "$repo/branches/branch"
svn merge -r "$branchrev:HEAD" "$repo/trunk"
svn ci -m 'attempt to merge file->symlink transition'

(end script)

I went ahead and opened an issue
(http://subversion.tigris.org/issues/show_bug.cgi?id=2530), then read
that I'm supposed to check the bug out here first. My apologies.

-- 
error compiling committee.c: too many arguments to function
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Fri Mar 24 13:11:32 2006

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.