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

Re: [svn] Problem with Peg Revisions and files containing '@'

From: Eli Barzilay <eli_at_barzilay.org>
Date: 2005-06-01 23:01:12 CEST

On Jun 1, kfogel@collab.net wrote:
> Eli Barzilay <eli@barzilay.org> writes:
> > On May 31, Eli Barzilay wrote:
> > > (submitting an issue, FWIW.)
> >
> > OK, so it seems like this is impossible without registration,
> > which will not go through immediately. I'll post it here
> > instead...
>
> Yeah, I wish it were possible for us to set the website to
> automatically approve all requests for 'Observer' role (or to simply
> not require it for issue filings).

(BTW, the whole bug report thing is really difficult to follow.)

> > It seems like there is no way to escape a real `@' character which is
> > part of a file name. Looking at the code in
> > "subversion/libsvn_subr/opt.c", this behavior hard wired with no way
> > to avoid it. It also looks like standard escaping will not be
> > convenient since it's only needed for the last `@' in a filename.
> >
> > The way to avoid this currently is to append a `@BASE' to the path.
> > If nothing else is changed, then its probably a good idea to mention
> > this in some docs. It would be better to actually come up with a
> > proper solution which can be used in scripts etc. I guess that having
> > a rule that the `@' is interpreted as part of a path if that path
> > exists is impossible when considering URLs.
>
> +1 on both.
>
> The workaround should be documented, but the more intuitive solution
> would be for "@" to quote itself. That's what many people probably
> expect anyway.

If you're talking about making "@@" represent "@", then that's not a
good idea... The problem is that only the last "@" need quoting,
which will be difficult to remember and to implement in scripts. The
other option is to force quoting all "@"s like that which is even less
pleasant (at least IMO).

> > So how about making an empty peg revision be used as the default?
> > Then the only escape that will be needed to guarantee proper behavior
> > in scripts is to use "path@".
>
> We should also do that, IMHO.

This seems to be the most convenient thing -- for both usets and for
scripting.

> > Another thing that seems like it should be working is to use "path/".
> > It's questionable (IMO) whether this should be working, but it seems
> > to be working for plain file paths. However, with a `@', it fails
> > with the same
> >
> > svn proplist foo@bar/
> > svn: Syntax error parsing revision 'bar'
> >
> > which seems strange since the code in the above file look like it
> > stops as soon as it hits a `/'.
>
> I don't think we should be allowing trailing '/' on files, but
> that's sort of a separate issue.
>
> Do you have Observer role now? Would you mind filing the "@" issue,
> and if you're really feeling squirrely, the "/" issue too? If so,
> please refer to this mail thread from both issues.

Yes, I'll do that now.

-- 
          ((lambda (x) (x x)) (lambda (x) (x x)))          Eli Barzilay:
                  http://www.barzilay.org/                 Maze is Life!
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Wed Jun 1 23:05:08 2005

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