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

Making import syntax more consistant (Was Re: making repositories)

From: Peter Davis <peter_at_pdavis.cx>
Date: 2002-10-14 21:30:53 CEST

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

To anyone who cares, read the following, and if you have ever been confused by
"svn import" before as I have, please post your comments. If you haven't
ever been confused, then please post why you think this change would be a bad
idea. Thanks!

On Monday 14 October 2002 11:34, you wrote:
> I'm not sure I understand what you're proposing. Could you give an
> example of the way someone would have to do something now, versus how
> it would be after the proposed change?

Right now, we use "svn import" as:

$ svn import REPOS_URL [PATH] [NEW_ENTRY_IN_REPOS]

I propose:

$ svn import REPOS_URL[/NEW_ENTRY] [PATH]

My problems with the current scheme:

(1) AFAIK, import is the only command where REPOS_URL and ENTRY_IN_REPOS are
separate. This is inconsistant.

(2) Not only are they separate, but there is another argument between them.
Many times have I been burned by accidentally switching PATH and
NEW_ENTRY_IN_REPOS. This is confusing.

All of the current use cases could be accounted for by the change. If you
have a working copy with a single file "foo" in the directory "working-copy":

(1) $ svn import url://repos/new-entry working-copy
Create directory new-entry/ in repository and copy contents of working-copy
into that directory. You end up with "url://repos/new-entry/foo".

(2) $ svn import url://repos/ working-copy
Same thing, but without creating "new-entry/". You end up with
"url://repos/foo".

(3) $ svn import url://repos/
Copy contents of current directory into repository root. If the current
directory contains the working-copy directory, you end up with
"url://repos/working-copy/foo", along with all the other contents of the
current directory.

And, the change would provide one additional use case:

(4) $ svn import url://repos/new-entry
Create directory new-entry/ in repository and copy contents of current
directory there. You end up with "url://repos/new-entry/working-copy/foo".

which is impossible right now because you can't specify the third argument
without the second.

Much like removing the "-d" option from checkout, this change would probably
confuse existing users. But in the end, it would make a lot more sense, and
it is better to change it now before 1.0 makes a change impossible.

Are there technical reasons why the change would be impossible? Is there a
reason why it wasn't made like this in the first place? CVS's import is so
convoluted, I hope it burns in hell :), so I don't think CVS should be a
factor in any decision.

Thanks,
Peter Davis
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.7 (GNU/Linux)

iD8DBQE9qxtwhDAgUT1yirARAoVRAJwLAk7rgi6EZ60O0qLL0BR/BmvlpgCeMTyE
1M5DV3n/Se4o22XtqN5psAA=
=OxHl
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Mon Oct 14 21:31:35 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.