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

RE: "svn copy --parents" allows insertion of an errant '\' in http://path

From: Bert Huijben <bert_at_qqmail.nl>
Date: Wed, 7 May 2014 09:30:42 +0200

I think a

$ svn mv –parents http://svr/sandbox/A\B http://svr/sandbox/A/B -m "Renamed bad directory”

 

Should fix your repository.

 

Subversion doesn’t support ‘\’ in local paths, but on the server side there is no real problem with that character. So the trick is to avoid the working copy while fixing.

 

If you receive ugly http errors, you might have to perform this operation on the repository itself via <file:///\\> file:///, but I think it will work for you, or you would have received the same error when adding the path.

 

                Bert

 

From: Dan Ellis [mailto:danellis10_at_gmail.com]
Sent: woensdag 7 mei 2014 01:26
To: Subversion Users
Subject: "svn copy --parents" allows insertion of an errant '\' in http://path

 

Hi,

 

I pulled a silly mistake just now... I accidentally let my windows backslash enter into an http URL during an SVN copy operation.

 

copy --parents "C:\Project_files\sandbox\bar.c" "http://svr/sandbox/A\B/bar1.c <http://svr/sandbox/A/B/bar1.c> " -m "bad commit"

 

It successfully committed.

 

svn update now returns the following:

 

svn: E155000: 'A\B' is not a valid filename in directory 'C:\Project_files\sandbox\'

 

 First, I assume there should be a check to prevent this invalid character for URLs. Second, how do I undo my error?

 

I'm on SVN 1.8.5 and the backslash should give me away as a windows user (Win7 - 64bit).

 

Thanks for the help,

Dan

 

 
Received on 2014-05-07 22:07:51 CEST

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

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.