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

Re: Replacing symlink exhibits unexpected error

From: Mattius McLaughlin <Mattius_McLaughlin_at_pmc-sierra.com>
Date: Tue, 26 Jul 2011 14:10:59 -0700

On 07/19/11 12:04, Mattius McLaughlin wrote:
> Hi All,
>
> I'm encountering some strange behaviour with replacing a symlink
> with a real file in the repository and wanted to know if what I was
> seeing is a bug or whether I'm doing something wrong. I'd like to
> replace the file in one commit, but Subversion objects to changing the
> file type:
>
> % ls -l trunk/memory_ddr3.v
> lrwxrwxrwx 1 mclaughl eng 74 Jul 19 11:51 trunk/memory_ddr3.v ->
> /proj/ddr3/s39/s39a0c2762e5ac7f7
> % svn status trunk/memory_ddr3.v
> % svn rm trunk/memory_ddr3.v
> D trunk/memory_ddr3.v
> % cp /proj/ddr3/s39/s39a0c2762e5ac7f7 trunk/memory_ddr3.v
> % svn add trunk/memory_ddr3.v
> A trunk/memory_ddr3.v
> % svn status trunk/memory_ddr3.v
> R trunk/memory_ddr3.v
> % svn ci -m "Correcting link" trunk/memory_ddr3.v
> svn: Commit failed (details follow):
> svn: Entry '/home/mclaughl/nobackup/trunk/memory_ddr3.v' has
> unexpectedly changed special status
>

In case anyone stumbles across this later, the missing step here was to
remove the svn:special property as well as removing the file:

% ls -l trunk/memory_ddr3.v
lrwxrwxrwx 1 mclaughl eng 74 Jul 19 11:51 trunk/memory_ddr3.v ->
/proj/ddr3/s39/s39a0c2762e5ac7f7
% svn status trunk/memory_ddr3.v
% svn rm trunk/memory_ddr3.v
D trunk/memory_ddr3.v
% svn propdel svn:special trunk/memory_ddr3.v
property 'svn:special' deleted from 'trunk/memory_ddr3.v'.
% cp /proj/ddr3/s39/s39a0c2762e5ac7f7 trunk/memory_ddr3.v
% svn add trunk/memory_ddr3.v
A trunk/memory_ddr3.v
% svn status trunk/memory_ddr3.v
R trunk/memory_ddr3.v
% svn ci -m "Correcting link" trunk/memory_ddr3.v
Replacing trunk/memory_ddr3.v
Transmitting file data .
Committed revision 20311.

I'm surprised the client can't handle this automatically, but I suppose
it's a fairly rare use case.

--Mattius McLaughlin
Received on 2011-07-26 23:11:36 CEST

This is an archived mail posted to the Subversion Users mailing list.