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

Re: Making import syntax consistant with mv, cp, export

From: B. W. Fitzpatrick <fitz_at_red-bean.com>
Date: 2002-10-16 22:33:09 CEST

Peter Davis <peter@pdavis.cx> writes:

> Remembering to include "graphics/" but not "bsp/" in the URL is the only
> problem I see with this.
>
> Maybe import should not automatically create parent directories?

Hmmm. even tho I was -1 on svn mkdir -p, I'm +1 on svn import
automatically creating parent directories. Hmmm...

> Maybe this is another possible use for a global "-p" or "--create-parents"
> option, which would apply both to mkdir and to import in this case, and could
>
> be extended to cp and mv as well. I believe that option was rejected because
> it was only used by mkdir.

I think there's a misunderstanding here. Maybe some examples would
help clarify the proposed behavior of import.

If we have directory with one file in it like this:

    /home/fitz/docs/svn/client/somefile.txt

Here are some scenarios:

$ cd /home/fitz/docs
$ svn import . http://svn.collab.net/repos/testdocs/trunk

The above would give you

http://svn.collab.net/repos/testdocs/trunk/somefile.txt

--
$ cd /home/fitz/docs
$ svn import . http://svn.collab.net/repos/testdocs/trunk/docs
The above would give you 
http://svn.collab.net/repos/testdocs/trunk/docs/somefile.txt
(Probably not what you want)
--
$ cd /home/
$ svn import fitz/docs http://svn.collab.net/repos/testdocs/trunk
The above would give you 
http://svn.collab.net/repos/testdocs/trunk/fitz/docs/somefile.txt
(Most likely not what you want)
--
$ cd /home/
$ svn import fitz/docs http://svn.collab.net/repos/trunk/fitz/docs
The above would give you 
http://svn.collab.net/repos/testdocs/trunk/fitz/docs/fitz/docs/somefile.txt
(definitely not what you want)
--
Anyway, my whole point here is that our behavior shouldn't be a mass
of special cases, but we should grab the first argument to import and
copy that directly into the second argument's location in the
repository without any munging or funny business.
-Fitz
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Wed Oct 16 22:33:54 2002

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.