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

Re: "The system cannot find the file specified" during update

From: Ruslan Sivak <russ_at_vshift.com>
Date: Thu, 23 Oct 2008 00:27:04 -0400

Ryan Schmidt wrote:
>
> DOS/Windows line endings are \r\n, not \n\r. But you can't use tr like
> that. It translates each character of the first argument to the
> corresponding character in the second argument. If, as in your case,
> there is only one character in the second argument, it replaces each
> character from the first argument with the character from the second
> argument. So all "\r" characters are being translated to null, and all
> "\n" characters are being translated to null. Hence you have a blank
> line between each line.
>
> You may instead want to use tr twice, once to delete the "\r"
> characters that come from being on Windows, and the second time to
> translate the "\n" characters to nulls.
>
> svn st --depth=infinity \
> | sed -n "s/^\! //p" \
> | tr -d "\r" \
> | tr "\n" "\0" \
> | xargs -0 -n 1 svn rm
>

Ryan,

Thank you for your help. This seemed to do the trick. My final script
is below. I still wish this would be included in the svn binary
somewhere, as it feels very much like a hack.

cd somefolder
svn add --force .
svn st --depth=infinity | sed -n "s/^\! //p" |tr -d "\r" | tr "\n"
"\0" | xargs -0 -n 1 --verbose -ixxx --no-run-if-empty svn rm \"xxx\"
svn commit -m "daily commit"

Russ

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe_at_subversion.tigris.org
For additional commands, e-mail: users-help_at_subversion.tigris.org
Received on 2008-10-23 06:27:30 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.