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

Re: Command line repository root relative URLs

From: Julian Foad <julianfoad_at_btopenworld.com>
Date: 2007-11-04 01:46:54 CET

Troy Curtis Jr wrote:
> For consistency, I am planning on using the same syntax used in
> relative-externals, namely "^/path/in/repo".
> The intent here is for this to be a VERY convenient short cut when
> dealing with "full" URLs. [...]

Excellent. It seems quite a "clean" improvement to the usability of commands
dealing with branches and tags especially.

Some drive-by thoughts while I'm thinking them...

What do you think should be the exact meaning of the shortcut? Something like:

   The "^" shall be substituted by the Repository Root
   of the current working directory;
   if the current working directory is not a SVN WC then throw an error.
   SVN's URL character auto-escaping shall be applied to the portion after "^/".

For example, if my working copy is ~/wc:

   $ cd ~/wc
   $ svn copy . ^/tags/newtag

but not

   $ cd ~
   $ svn copy wc ^/tags/newtag
   svn: '/home/julian' is not a working copy
   svn: cannot parse URL '^/tags/newtag' # or some such error message(s)

One could be tempted to say things like, if there's a local path involved in
the command, then look for the repository of that as well or instead of the
current directory. I suspect that way would lie madness but maybe current
working directory isn't the only possible rule.

It would be interesting to show a set of typical usage scenarios - tagging,
branching, merging, listing contents, etc. - with the exact realistic commands.

Certainly I agree that restricting the syntax to begin with "^/" is the right
way to start, as this leaves clear ways to extend it later, maybe with ".." and
such but also things like "^<repos-nickname>/" which could be configured
somewhere and then used from anywhere. There's no shortage of ideas around this
theme; first the important thing is to get something solid and simple and
useful in place.

- Julian

To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Sun Nov 4 01:47:07 2007

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.