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.
$ 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
> 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
I agree the behaviour is surprising when you encounter it the way you
did, but it's easily understandable when you read the help.
> Additionally, poking around the export code has demonstrated a number
> of scenarios where it falls flat on its face. *sigh*
Received on 2009-11-13 18:31:38 CET