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

Re: svn URL's with '..' elements

From: Chris Pickett <chris.pickett_at_mail.mcgill.ca>
Date: 2005-02-28 20:20:12 CET

Chris Pickett wrote:
> Vincent Lefevre wrote:
>
>> On 2005-02-24 11:08:59 -0800, Ben Reser wrote:
>>
>>> Firefox gives /home/breser if you ask fore
>>> file:///home/breser/foo-tmp/..
>>
>>
>>
>> Ditto for Mozilla, links and w3m. However lynx gives the root directory,
>> but IMHO this is a bug. The .. rule for URLs is described for relative
>> URLs only (RFCs 1808 and 2396), but for consistency, it would be a good
>> idea to use this rule for absolute URLs too IMHO.
>
>
> I think saying .. always removes one element from the specified path and
> documenting that clearly would be a good solution.

More specifically, saying that:

1) ./ is prepended to relative paths that do not have it there

2) ./ at the beginning of a path is converted to the same absolute path
pwd gives you, or simply removed if not at the beginning

3) .. then removes one element from the preceding path, and symlinks are
never followed.

4) /.. == /

$ ls -l foo-tmp
lrwxrwxrwx 1 chris users 4 2005-02-28 14:06 foo-tmp -> /tmp

$ svn ls foo-tmp/..
->
svn ls ./foo-tmp/..
->
svn ls /home/chris/foo-tmp/..
->
svn ls /home/chris

As a user, I having svn not follow symlinks is the behaviour I want. If
I have foo-tmp linked to a directory in a WC, then currently:

$ svn ls foo-tmp/..
svn: '.' is not a working copy

$ cd foo-tmp/
svn ls ..
[follows symlink and lists contents]

So I guess either way, there are things here that need to be fixed.

Chris

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Mon Feb 28 20:22:22 2005

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.