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

Re: svn commit: r40485 - in trunk/subversion: svn tests/cmdline

From: Julian Foad <julianfoad_at_btopenworld.com>
Date: Fri, 13 Nov 2009 17:31:01 +0000

Hyrum K. Wright wrote:
> On Nov 12, 2009, at 5:41 PM, Julian Foad wrote:
> > Hyrum K. Wright wrote:
> >> Make "svn export $repos/blah '.'" do what you think it would, namely, put a
> >> file named "blah" into the cwd.
[...]
> > I understand why you did it, but... ugh. Special case. The built-in help
> > doesn't describe it. "." now behaves differently from
> > "../name-of-this-dir". Are you sure you really really want this?
>
> I don't know what the current behavior of 'svn export
> $url ../this-dir' is.

julianfoad_at_edith ~/src/subversion-cyan/tt
$ svn export $SVN_REPOS/trunk/www ../tt
svn: Destination directory exists; please remove the directory or use
--force to overwrite
svn: '../tt' already exists

> I *do* know that a one-argument export uses the cwd as the export
> target,

Yes.

> and explicitly supplying the cwd should behave the same as implicitly
> supplying one via the one-argument mechanism.

No. It is explicitly documented as behaving differently depending on
whether you supply a directory argument. Always has been:

[[[
$ svn export --help
export: Create an unversioned copy of a tree.
usage: 1. export [-r REV] URL[@PEGREV] [PATH]
       2. export [-r REV] PATH1[@PEGREV] [PATH2]

  1. Exports a clean directory tree from the repository specified by
     URL, at revision REV if it is given, otherwise at HEAD, into
     PATH. If PATH is omitted, the last component of the URL is used
     for the local directory name.
[...]
]]]

Not, as in most other commands, "If PATH is omitted then '.' is
assumed."

I agree the behaviour is surprising when you encounter it the way you
did, but it's easily understandable when you read the help.

- Julian

> Additionally, poking around the export code has demonstrated a number
> of scenarios where it falls flat on its face. *sigh*

------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=2417659
Received on 2009-11-13 18:31:38 CET

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.