You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Greg Stein <gs...@lyra.org> on 2000/10/17 07:00:56 UTC
cmd line stuff (was: CVS update: ...)
On Tue, Oct 17, 2000 at 12:05:49AM -0000, kfogel@tigris.org wrote:
>...
> +A start on global options:
> +
> + -r repository Use REPOSITORY.
Wouldn't this be an argument to the checkout command? Or are we planning to
allow some of the commands when a working copy does not exist? e.g. why
specify the repository for an "update" ?
> + -f Suppress reading of .svnrc.
> + -h -H --help [command] Like CVS: get general or cmd-specific help.
> + --help-options (Also like the CVS help scheme.)
> + --help-commands (Same.)
> + --dry-run Like cvs -n
> + -q Quiet. (No need for two levels of this?)
> + -v --version Print program name, version, and url.
-v for verbose? Will we have a verbose option? [and version would be -V]
> +And the commands will look a lot like CVS's, though there are some
> +newcomers:
> +
> + checkout | co
> + update | up
> + commit | ci
> + add | ad | new
> + rename | mv
> + delete | del | rm
> + copy | cp
> + branch /* implemented via copy, though may want to be its own command */
> + tag /* implemented via copy, though may want to be its own command */
> + status | stat
> + diff | di | dif
> + rdiff
what the heck is rdiff?
> + annotate | ann
> + import | im | imp
export?
> + history | hi | his
> + log | lo
how are history and log different?
> + propset | pset
> + propget | pget
Will we have a "login" command? A URL can specify a user/password, but I'm
sure many people will want prompts to keep the pwd off the cmd line.
Speaking of: I think we can skip that whole "munge the pwd before storing in
.cvspass" is bogus. Just store it in clear text and chmod the file properly.
The cmd line should abort operation if the perms on that file are incorrect
("your .svnrc file has incorrect permissions, please set to 0600" or
whatever).
Along a similar line, there are going to be different ways to authenticate
with the server. Sometimes, we may not even have a password :-) Other times,
we need to somehow figure out where a client-side certificate is stored.
> +Some command-specific options are unique to that command, but others
> +are common to several commands, for example:
> +
> + -v version Like "cvs cmd -r REV"
urk. Is it possible to avoid duplicate letters between the global and local
options? Dunno how much people confuse them, but it might be a nice start.
Cheers,
-g
--
Greg Stein, http://www.lyra.org/
Re: "modules" (was: Re: cmd line stuff)
Posted by Jim Blandy <ji...@savonarola.red-bean.com>.
Karl Fogel <kf...@galois.collab.net> writes:
> Jim Blandy <ji...@savonarola.red-bean.com> writes:
> > Don't worry, this has nothing to do with the form of the URL's --- it
> > will be managed completely within the filesystem.
>
> Jim, is your idea of "union nodes" to support modules documented
> somewhere? It's really winning, and I think people's curiosity is
> being tantalized now... :-)
It's not documented anywhere...
Re: "modules" (was: Re: cmd line stuff)
Posted by Karl Fogel <kf...@galois.collab.net>.
Jim Blandy <ji...@savonarola.red-bean.com> writes:
> Don't worry, this has nothing to do with the form of the URL's --- it
> will be managed completely within the filesystem.
Jim, is your idea of "union nodes" to support modules documented
somewhere? It's really winning, and I think people's curiosity is
being tantalized now... :-)
Re: "modules" (was: Re: cmd line stuff)
Posted by Lee Burgess <le...@red-bean.com>.
Jim Blandy writes:
>
> > > > Please correct me if svn is not going to support modules like cvs; or
> > > > if a module in svn would just be something like a symlink?
> > >
> > > Modules in Subversion are simply subdirectories of the filesystem. To
> > > get some of the more sophisticated behavior of CVS's modules file,
> > > we're going to provide new kinds of directories, whose contents are
> > > computed from other directories.
> >
> > Um. I'm not sure that I follow this, or if it is hand-waving at this point.
>
> Don't worry, this has nothing to do with the form of the URL's --- it
> will be managed completely within the filesystem.
God love ya Jim.
All hail to the black box!
--
Lee P. W. Burgess <<!>> Manipulate eternity. Power is a symphony:
Programmer <<!>> elaborate, enormous, essential.
Red Bean Software <<!>> Dream the moment with a fiddle in summer
lefty@red-bean.com <<!>> and a knife in winter.
Re: "modules" (was: Re: cmd line stuff)
Posted by Jim Blandy <ji...@savonarola.red-bean.com>.
> > > Please correct me if svn is not going to support modules like cvs; or
> > > if a module in svn would just be something like a symlink?
> >
> > Modules in Subversion are simply subdirectories of the filesystem. To
> > get some of the more sophisticated behavior of CVS's modules file,
> > we're going to provide new kinds of directories, whose contents are
> > computed from other directories.
>
> Um. I'm not sure that I follow this, or if it is hand-waving at this point.
Don't worry, this has nothing to do with the form of the URL's --- it
will be managed completely within the filesystem.
"modules" (was: Re: cmd line stuff)
Posted by Greg Stein <gs...@lyra.org>.
On Tue, Oct 17, 2000 at 01:54:13PM -0500, Jim Blandy wrote:
>
> > However, one thing that occurs to me is how would one specify a module
> > with that command syntax?
> >
> > Please correct me if svn is not going to support modules like cvs; or
> > if a module in svn would just be something like a symlink?
>
> Modules in Subversion are simply subdirectories of the filesystem. To
> get some of the more sophisticated behavior of CVS's modules file,
> we're going to provide new kinds of directories, whose contents are
> computed from other directories.
Um. I'm not sure that I follow this, or if it is hand-waving at this point.
At the moment, an SVN repository is a URL. You give the client a URL and it
does the rest. The server figures out what it wants to do with that URL.
I don't understand what else is being suggested here, and/or how you can
compose/mix these URLs.
Cheers,
-g
--
Greg Stein, http://www.lyra.org/
Re: cmd line stuff (was: CVS update: ...)
Posted by Ben Collins-Sussman <su...@newton.collab.net>.
Branko =?iso-8859-2?Q?=C8ibej?= <br...@xbc.nu> writes:
> Jim Blandy wrote:
> > Modules in Subversion are simply subdirectories of the filesystem. To
> > get some of the more sophisticated behavior of CVS's modules file,
> > we're going to provide new kinds of directories, whose contents are
> > computed from other directories.
>
> Way to go! I meant to propose something like this, but hadn't got around
> to it.
People might be very interested in reading (refreshing memories) of
exactly how the filesystem works. Branches and tags are just nodes
that point to existing trees; they appear to be ordinary directories.
And, as Jim says, a CVS "module" can be emulated by creating Union
directories, much as BSD does. There's all sorts of details in the
middle of the spec:
http://subversion.tigris.org/svn-design.html#TOC_41
Re: cmd line stuff (was: CVS update: ...)
Posted by Karl Fogel <kf...@galois.collab.net>.
pohl <po...@screaming.org> writes:
> To learn. 8^) Sorry, I just had to speak up for anklebiters like
> myself who know something cool is happening here but aren't in the
> same league as y'all.
Nah, don't get frightened off. There are lots of terms flying around,
but they all refer to things you either know already or would
understand in 10 seconds once explained.
Re: cmd line stuff (was: CVS update: ...)
Posted by pohl <po...@screaming.org>.
Branko <br...@xbc.nu> wrote:
>
> Way to go! I meant to propose something like this, but hadn't got around
> to it. In fact I wanted to point out that
>
> Modules are Configurations
>
> For anyone not familiar with the term (what're you doing on the SVN
> list then?)...
To learn. 8^) Sorry, I just had to speak up for anklebiters like
myself who know something cool is happening here but aren't in the
same league as y'all.
----
pohl@screaming.org
Re: modules (was: Re: cmd line stuff)
Posted by Greg Stein <gs...@lyra.org>.
On Mon, Oct 23, 2000 at 09:04:22AM -0500, Karl Fogel wrote:
> Greg Stein <gs...@lyra.org> writes:
> > I could easily see us handling this through HTTP redirects. For example, we
> > could have the "apr" subdir redirect to the APR repository, pointing at the
> > proper version. As an SVN checkout occurs, it hits the apr subdir, redirects
> > over to the APR repository, grabs it, then continues checking out from the
> > SVN repository.
>
> Hmm!
>
> Cross-repository links may be easier than we ever thought...
Assuming they both use SVN (well, DeltaV really), then yah!
Within libsvn_ra_dav, I keep a URL as I navigate thru the checkout process.
If that URL suddenly points somewhere else for a portion of the checkout?
*shrug* No big deal :-)
We will definitely want [the client] to pay attention to redirects. This
will allow us to move repositories ("oops! not at svn.tigris.org any more...
it is now at subversion.org"), to do the cross-repository stuff, and even to
support a pseudo multiple repository system.
Consider: you have a "master" repository that gets copied out to slave
sites. John Doe does a checkout from the slave site, makes some changes, and
then does a commit. The slave goes "hey... I'm not the master, go <here> to
execute the commit."
Food for thought...
Cheers,
-g
--
Greg Stein, http://www.lyra.org/
Re: modules (was: Re: cmd line stuff)
Posted by Karl Fogel <kf...@galois.collab.net>.
Greg Stein <gs...@lyra.org> writes:
> I could easily see us handling this through HTTP redirects. For example, we
> could have the "apr" subdir redirect to the APR repository, pointing at the
> proper version. As an SVN checkout occurs, it hits the apr subdir, redirects
> over to the APR repository, grabs it, then continues checking out from the
> SVN repository.
Hmm!
Cross-repository links may be easier than we ever thought...
modules (was: Re: cmd line stuff)
Posted by Greg Stein <gs...@lyra.org>.
On Mon, Oct 23, 2000 at 02:32:07AM +0200, Branko Cibej wrote:
>...
> Something like that. For instance, right now we import APR into the
> SVN tree, but it doesn't happen magically -- you have to do the checkout
> by hand. Sooner or later, APR will have a stable release, tagged in the
> APR repo, and we may decide to use only stable releases of APR in SVN.
> So the checkout instructions for APR will change to include the correct
> tag, and whoever does a `cvs update -A' from the top of the tree gets
> what they deserve. Obviously, that's not a stable situation.
>
> If instead the fact that SVN is using APR revision 'foo' were a property
> of the 'apr' subdir of the SVN tree, that wouldn't be a problem, and
> sticky tags could probably go away completely.
>
> CVS's notion of alias modules is almost equivalent to configurations,
> except that you can't specify the version (tag) and repository of each
> member.
>
> Oh yes -- configurations can be embedded anywhere in the tree, like
> directories; and their contents should be version-controlled, of course.
I could easily see us handling this through HTTP redirects. For example, we
could have the "apr" subdir redirect to the APR repository, pointing at the
proper version. As an SVN checkout occurs, it hits the apr subdir, redirects
over to the APR repository, grabs it, then continues checking out from the
SVN repository.
Cheers,
-g
--
Greg Stein, http://www.lyra.org/
Re: cmd line stuff (was: CVS update: ...)
Posted by Branko Čibej <br...@xbc.nu>.
Michael Livshin wrote:
> > For anyone not familiar with the term (what're you doing on the SVN
> > list then?)
>
> stalking. why?
>
> [ oops ;) ]
Yeah, I should've put a smiley at the end of that paren. Sorry.
>
> > I hate sticky tags, they stick to the wrong places.
>
> you mean they stick to individual files but should stick to
> hierarchies instead?
Something like that. For instance, right now we import APR into the
SVN tree, but it doesn't happen magically -- you have to do the checkout
by hand. Sooner or later, APR will have a stable release, tagged in the
APR repo, and we may decide to use only stable releases of APR in SVN.
So the checkout instructions for APR will change to include the correct
tag, and whoever does a `cvs update -A' from the top of the tree gets
what they deserve. Obviously, that's not a stable situation.
If instead the fact that SVN is using APR revision 'foo' were a property
of the 'apr' subdir of the SVN tree, that wouldn't be a problem, and
sticky tags could probably go away completely.
CVS's notion of alias modules is almost equivalent to configurations,
except that you can't specify the version (tag) and repository of each
member.
Oh yes -- configurations can be embedded anywhere in the tree, like
directories; and their contents should be version-controlled, of course.
--
Brane �ibej
home: <br...@xbc.nu> http://www.xbc.nu/brane/
ACM: <br...@acm.org> http://www.acm.org/
Re: cmd line stuff (was: CVS update: ...)
Posted by Michael Livshin <ml...@bigfoot.com>.
Branko �ibej <br...@xbc.nu> writes:
> Jim Blandy wrote:
> > Modules in Subversion are simply subdirectories of the filesystem. To
> > get some of the more sophisticated behavior of CVS's modules file,
> > we're going to provide new kinds of directories, whose contents are
> > computed from other directories.
>
> Way to go!
yeah, neat.
and I wouldn't be surprised if later some crazy person will take this
filesystem code and use it as the basis for Hurd versioned filesystem,
or something.
> Modules are Configurations
>
> For anyone not familiar with the term (what're you doing on the SVN
> list then?)
stalking. why?
[ oops ;) ]
> I hate sticky tags, they stick to the wrong places.
you mean they stick to individual files but should stick to
hierarchies instead?
--
I have seen the future, and it does not work.
Re: cmd line stuff (was: CVS update: ...)
Posted by Karl Fogel <kf...@galois.collab.net>.
Branko =?iso-8859-2?Q?=C8ibej?= <br...@xbc.nu> writes:
> Modules are Configurations
>
> For anyone not familiar with the term (what're you doing on the SVN
> list then?),
I'm not familiar with the term, at least not in the highly specific
sense you're using it.
> a configuration in the CM sense is a collection of object
> versions -- somewhat like a directory, except that you can collect
> objects from different directories -- even different repositories --
> and membership in a configuration isn't necessarily limited to a
> specific version, it can be a symbolic name, too -- a tag, that is.
Okay, thanks. Am familiar with the concept, just wasn't aware that
"configuration" was always the accepted term for this concept.
> I've always wanted to be able to tell CVS to follow the tip of
> branch A in directory B in repository C, and remember that in the
> repo, without that sticky tags crud ... I hate sticky tags, they
> stick to the wrong places.
Yeah, same.
Re: cmd line stuff (was: CVS update: ...)
Posted by Branko Čibej <br...@xbc.nu>.
Karl Fogel wrote:
>
> Peace, peace -- I think Branko mentioned that he just forgot to put a
> smiley face. :-)
Aye, apologies to all.
(Note to self: get off jet lag before posting.)
--
Brane �ibej
home: <br...@xbc.nu> http://www.xbc.nu/brane/
ACM: <br...@acm.org> http://www.acm.org/
Re: cmd line stuff (was: CVS update: ...)
Posted by Karl Fogel <kf...@galois.collab.net>.
Peace, peace -- I think Branko mentioned that he just forgot to put a
smiley face. :-)
Greg Stein <gs...@lyra.org> writes:
> I'm still on the list because I don't need to know the darn term to get my
> work done. Nor do I need somebody implying that I shouldn't be here or that
> I'm not as smart as someone else because I don't happen to know some term
> from some domain-specific body of knowledge.
>
> Cheers,
> -g
>
> --
> Greg Stein, http://www.lyra.org/
Re: cmd line stuff (was: CVS update: ...)
Posted by Greg Stein <gs...@lyra.org>.
On Mon, Oct 23, 2000 at 12:07:36AM +0200, Branko Cibej wrote:
> Jim Blandy wrote:
> > Modules in Subversion are simply subdirectories of the filesystem. To
> > get some of the more sophisticated behavior of CVS's modules file,
> > we're going to provide new kinds of directories, whose contents are
> > computed from other directories.
>
> Way to go! I meant to propose something like this, but hadn't got around
> to it. In fact I wanted to point out that
>
> Modules are Configurations
>
> For anyone not familiar with the term (what're you doing on the SVN
> list then?),
I'm still on the list because I don't need to know the darn term to get my
work done. Nor do I need somebody implying that I shouldn't be here or that
I'm not as smart as someone else because I don't happen to know some term
from some domain-specific body of knowledge.
Cheers,
-g
--
Greg Stein, http://www.lyra.org/
Re: cmd line stuff (was: CVS update: ...)
Posted by Branko Čibej <br...@xbc.nu>.
Jim Blandy wrote:
> Modules in Subversion are simply subdirectories of the filesystem. To
> get some of the more sophisticated behavior of CVS's modules file,
> we're going to provide new kinds of directories, whose contents are
> computed from other directories.
Way to go! I meant to propose something like this, but hadn't got around
to it. In fact I wanted to point out that
Modules are Configurations
For anyone not familiar with the term (what're you doing on the SVN
list then?), a configuration in the CM sense is a collection of object
versions -- somewhat like a directory, except that you can collect
objects from different directories -- even different repositories --
and membership in a configuration isn't necessarily limited to a
specific version, it can be a symbolic name, too -- a tag, that is.
I've always wanted to be able to tell CVS to follow the tip of
branch A in directory B in repository C, and remember that in the
repo, without that sticky tags crud ... I hate sticky tags, they
stick to the wrong places.
--
Brane �ibej
home: <br...@xbc.nu> http://www.xbc.nu/brane/
ACM: <br...@acm.org> http://www.acm.org/
Re: cmd line stuff (was: CVS update: ...)
Posted by Jim Blandy <ji...@savonarola.red-bean.com>.
> However, one thing that occurs to me is how would one specify a module
> with that command syntax?
>
> Please correct me if svn is not going to support modules like cvs; or
> if a module in svn would just be something like a symlink?
Modules in Subversion are simply subdirectories of the filesystem. To
get some of the more sophisticated behavior of CVS's modules file,
we're going to provide new kinds of directories, whose contents are
computed from other directories.
Re: cmd line stuff (was: CVS update: ...)
Posted by Lee Burgess <le...@red-bean.com>.
Jim Blandy writes:
>
> I've added my old command-line notes to subversion/client/README. Here
> are the ideas I thought were worthwhile:
>
> * It seems kind of archaic to type:
>
> svn -d REPO-SPEC checkout MODULE
>
> This splits the information `what am I checking out' across two
> different places. It would be nicer to simply name the thing you're
> checking out, using some appropriate noun clause. For remote things,
> URL's are the natural kind of noun clause:
>
> svn checkout http://subversion.tigris.org/repo/subversion
>
> I don't know if this is exactly the DAV way; maybe Greg can provide a
> more realistic example. But the important idea is that the syntax
> should be:
>
> svn checkout THING
>
>
> * Given Subversion's idea that the repository is just a versioned
> filesystem, it makes sense to allow some operations directly on the
> repository. For example, if I want to copy a tree, so I can start
> work on a separate branch of development, I shouldn't have to check
> out this huge tree, copy a big section of it, and then commit that.
>
> Just as I can say:
>
> svn cp SOURCE DEST
>
> to copy something in my working directory, I should be able to use
> URL's for SOURCE and / or DEST, and have the right thing happen. It's
> the same idea behind rcp / scp: instead of providing one command for
> downloading, and a separate command for uploading, just provide a
> syntax for referring to files elsewhere, and let the names tell you
> how the data needs to flow.
>
> Since we don't support inter-repository branching yet, we would
> require for now that when SOURCE or DEST are remote, they must refer
> to the same repository.
I like this idea a lot (Many good ideas today)!
However, one thing that occurs to me is how would one specify a module
with that command syntax?
Please correct me if svn is not going to support modules like cvs; or
if a module in svn would just be something like a symlink?
Maybe I should read the spec? Forgive me if I am being obtuse; I have
been lurking on the list for some time, but still have a lot to catch
up on. :)
--
Lee P. W. Burgess <<!>> Manipulate eternity. Power is a symphony:
Programmer <<!>> elaborate, enormous, essential.
Red Bean Software <<!>> Dream the moment with a fiddle in summer
lefty@red-bean.com <<!>> and a knife in winter.
Re: cmd line stuff (was: CVS update: ...)
Posted by Greg Stein <gs...@lyra.org>.
On Tue, Oct 17, 2000 at 11:56:09AM -0500, Karl Fogel wrote:
>...
> Am worried about using "http://" URLs, because what if your repository
> and project home page are on the same server, but you want to call
> them by the same name (say, `comp-tools'). Then does
>
> http://www.mydomain.org/comp-tools
>
> refer to the home page or the top of your repository? Or perhaps the
> web server is configured to point certain names at corresponding
> repositories, like:
>
> http://www.mydomain.org/myrepos/comp-tools
>
> And httpd.conf has something like
>
> SubversionAlias myrepos /usr/share/svn/repositories/my_public_repos
>
> or whatever. That might work out okay, yeah.
URLs will take the form of your second example. Repositories are placed
where the adminstrator wants. (i.e. they don't just "appear" under the root
space of a host)
httpd.conf will actually look something like:
<Location /myrepos/comp-tools>
DAV svn
SVNPath /usr/share/svn/repositories/my_public_repos
# auth info goes here
<Limit ... some methods>
Require group devguys
</Limit>
</Location>
Cheers,
-g
--
Greg Stein, http://www.lyra.org/
Re: cmd line stuff (was: CVS update: ...)
Posted by Greg Stein <gs...@lyra.org>.
hehe... here I am, going thru the days email (after a serious amount of glen
morangie, mind you), replying here and there... and what do you know?
Psychic Jim tells all :-)
I hope that my previous emails have cleared up some of the operation.
Disclaimer: as I see it.
Please ask questions and point out concerns. Obviously, if Jim and Karl
aren't intimate with these details, then it means one of three things: 1) it
hasn't been discussed before, 2) I have not been proactive enough, or 3) I
have been unclear in my explanations.
I tend to take (2). mod_dav_svn is starting to take form, so this is shaking
out, and we can start to mess around with what it really means. I doubt that
I'll have something meaningful before leaving for ApacheCon, but the week of
October 30th (first week of November), we will have an Apache-based server
that people can do a checkout from an SVN repository. As this comes
together, it should become clear. Worst part is that I doc for hell, unlike
Karl/Jim/Ben. Comments for clarity, sure. But proactive doc? Arg. They kick
my butt... I "feel my way" thru code, so advanced doc doesn't work.
Ah well. Recall the glen morangie. Just ask questions. I can answer :-)
Cheers,
-g
On Tue, Oct 17, 2000 at 02:57:58PM -0500, Jim Blandy wrote:
>
> Greg S. will explain everything to us, and we will become enlightened.
>
> Karl Fogel <kf...@galois.collab.net> writes:
>
> > Jim Blandy <ji...@savonarola.red-bean.com> writes:
> > > * It seems kind of archaic to type:
> > >
> > > svn -d REPO-SPEC checkout MODULE
> > >
> > > This splits the information `what am I checking out' across two
> > > different places. It would be nicer to simply name the thing you're
> > > checking out, using some appropriate noun clause. For remote things,
> > > URL's are the natural kind of noun clause:
> > >
> > > svn checkout http://subversion.tigris.org/repo/subversion
> > >
> > > I don't know if this is exactly the DAV way; maybe Greg can provide a
> > > more realistic example. But the important idea is that the syntax
> > > should be:
> > >
> > > svn checkout THING
> >
> > I like.
> >
> > Am worried about using "http://" URLs, because what if your repository
> > and project home page are on the same server, but you want to call
> > them by the same name (say, `comp-tools'). Then does
> >
> > http://www.mydomain.org/comp-tools
> >
> > refer to the home page or the top of your repository? Or perhaps the
> > web server is configured to point certain names at corresponding
> > repositories, like:
> >
> > http://www.mydomain.org/myrepos/comp-tools
> >
> > And httpd.conf has something like
> >
> > SubversionAlias myrepos /usr/share/svn/repositories/my_public_repos
> >
> > or whatever. That might work out okay, yeah.
--
Greg Stein, http://www.lyra.org/
Re: cmd line stuff (was: CVS update: ...)
Posted by Karl Fogel <kf...@galois.collab.net>.
Jim Blandy <ji...@savonarola.red-bean.com> writes:
> Greg S. will explain everything to us, and we will become enlightened.
That's what I'm hoping for, yes! :-)
> Karl Fogel <kf...@galois.collab.net> writes:
>
> > Jim Blandy <ji...@savonarola.red-bean.com> writes:
> > > * It seems kind of archaic to type:
> > >
> > > svn -d REPO-SPEC checkout MODULE
> > >
> > > This splits the information `what am I checking out' across two
> > > different places. It would be nicer to simply name the thing you're
> > > checking out, using some appropriate noun clause. For remote things,
> > > URL's are the natural kind of noun clause:
> > >
> > > svn checkout http://subversion.tigris.org/repo/subversion
> > >
> > > I don't know if this is exactly the DAV way; maybe Greg can provide a
> > > more realistic example. But the important idea is that the syntax
> > > should be:
> > >
> > > svn checkout THING
> >
> > I like.
> >
> > Am worried about using "http://" URLs, because what if your repository
> > and project home page are on the same server, but you want to call
> > them by the same name (say, `comp-tools'). Then does
> >
> > http://www.mydomain.org/comp-tools
> >
> > refer to the home page or the top of your repository? Or perhaps the
> > web server is configured to point certain names at corresponding
> > repositories, like:
> >
> > http://www.mydomain.org/myrepos/comp-tools
> >
> > And httpd.conf has something like
> >
> > SubversionAlias myrepos /usr/share/svn/repositories/my_public_repos
> >
> > or whatever. That might work out okay, yeah.
Re: cmd line stuff (was: CVS update: ...)
Posted by Jim Blandy <ji...@savonarola.red-bean.com>.
Greg S. will explain everything to us, and we will become enlightened.
Karl Fogel <kf...@galois.collab.net> writes:
> Jim Blandy <ji...@savonarola.red-bean.com> writes:
> > * It seems kind of archaic to type:
> >
> > svn -d REPO-SPEC checkout MODULE
> >
> > This splits the information `what am I checking out' across two
> > different places. It would be nicer to simply name the thing you're
> > checking out, using some appropriate noun clause. For remote things,
> > URL's are the natural kind of noun clause:
> >
> > svn checkout http://subversion.tigris.org/repo/subversion
> >
> > I don't know if this is exactly the DAV way; maybe Greg can provide a
> > more realistic example. But the important idea is that the syntax
> > should be:
> >
> > svn checkout THING
>
> I like.
>
> Am worried about using "http://" URLs, because what if your repository
> and project home page are on the same server, but you want to call
> them by the same name (say, `comp-tools'). Then does
>
> http://www.mydomain.org/comp-tools
>
> refer to the home page or the top of your repository? Or perhaps the
> web server is configured to point certain names at corresponding
> repositories, like:
>
> http://www.mydomain.org/myrepos/comp-tools
>
> And httpd.conf has something like
>
> SubversionAlias myrepos /usr/share/svn/repositories/my_public_repos
>
> or whatever. That might work out okay, yeah.
Re: cmd line stuff (was: CVS update: ...)
Posted by Karl Fogel <kf...@galois.collab.net>.
Jim Blandy <ji...@savonarola.red-bean.com> writes:
> * It seems kind of archaic to type:
>
> svn -d REPO-SPEC checkout MODULE
>
> This splits the information `what am I checking out' across two
> different places. It would be nicer to simply name the thing you're
> checking out, using some appropriate noun clause. For remote things,
> URL's are the natural kind of noun clause:
>
> svn checkout http://subversion.tigris.org/repo/subversion
>
> I don't know if this is exactly the DAV way; maybe Greg can provide a
> more realistic example. But the important idea is that the syntax
> should be:
>
> svn checkout THING
I like.
Am worried about using "http://" URLs, because what if your repository
and project home page are on the same server, but you want to call
them by the same name (say, `comp-tools'). Then does
http://www.mydomain.org/comp-tools
refer to the home page or the top of your repository? Or perhaps the
web server is configured to point certain names at corresponding
repositories, like:
http://www.mydomain.org/myrepos/comp-tools
And httpd.conf has something like
SubversionAlias myrepos /usr/share/svn/repositories/my_public_repos
or whatever. That might work out okay, yeah.
Re: cmd line stuff (was: CVS update: ...)
Posted by RADICS Peter <mi...@deneb.lbcons.net>.
On Wed, Oct 18, 2000 at 02:11:51AM -0700, Greg Stein wrote:
[SNIP]
> Regardless: in the example above, I would expect it to work exactly as
> typed, and that a directory named "subversion" would be created in the
> current dir. (e.g. take the last component as the top-level dir name)
Hm... I'd like it to be a bit more intelligent than that. Or dunno, just
a thought:
Let's assume I have
./projects/myproj1
./projects/myproj2
If I do
$ svn co http://myrepo.org/projects/myproj1
while staning in . (hm.. hope you know what I mean by . :),
then I'd like svn to check out only
./projects/myproj1
and leave ./projects/myproj2 alone, and I don't want it to check myproj1
out into ./myproj1 instead of ./projects/myproj1.
dunno if it's a good example, or not. thoughts?
[SNIP]
cheers,
mitch
--
// RADICS Peter <mi...@lbcons.net> (http://lbcons.net)
//
// "If human beings don't keep exercising their lips,
// their brains start working." -- Ford Prefect
Re: cmd line stuff (was: CVS update: ...)
Posted by Joe Orton <jo...@redhat.com>.
On Wed, 18 Oct 2000, Greg Stein wrote:
...
> This is *exactly* how I would envision this working, and is what the
> "ra-dav-test" does. You give it a URL and it checks the thing out. It needs
> an argument revamp now that WC is working well -- I think it currently
> requires a local dir to be specified or somesuch, and it creates an extra
> level of dir when it shouldn't.
I fixed the latter with my commit last night...
joe
Re: cmd line stuff (was: CVS update: ...)
Posted by Greg Stein <gs...@lyra.org>.
On Tue, Oct 17, 2000 at 01:26:07PM -0500, Jim Blandy wrote:
>...
> * It seems kind of archaic to type:
>
> svn -d REPO-SPEC checkout MODULE
>
> This splits the information `what am I checking out' across two
> different places. It would be nicer to simply name the thing you're
> checking out, using some appropriate noun clause. For remote things,
> URL's are the natural kind of noun clause:
>
> svn checkout http://subversion.tigris.org/repo/subversion
>
> I don't know if this is exactly the DAV way; maybe Greg can provide a
> more realistic example. But the important idea is that the syntax
> should be:
>
> svn checkout THING
This is *exactly* how I would envision this working, and is what the
"ra-dav-test" does. You give it a URL and it checks the thing out. It needs
an argument revamp now that WC is working well -- I think it currently
requires a local dir to be specified or somesuch, and it creates an extra
level of dir when it shouldn't.
Regardless: in the example above, I would expect it to work exactly as
typed, and that a directory named "subversion" would be created in the
current dir. (e.g. take the last component as the top-level dir name)
> * Given Subversion's idea that the repository is just a versioned
> filesystem, it makes sense to allow some operations directly on the
> repository. For example, if I want to copy a tree, so I can start
> work on a separate branch of development, I shouldn't have to check
> out this huge tree, copy a big section of it, and then commit that.
>
> Just as I can say:
>
> svn cp SOURCE DEST
>
> to copy something in my working directory, I should be able to use
> URL's for SOURCE and / or DEST, and have the right thing happen. It's
> the same idea behind rcp / scp: instead of providing one command for
> downloading, and a separate command for uploading, just provide a
> syntax for referring to files elsewhere, and let the names tell you
> how the data needs to flow.
>
> Since we don't support inter-repository branching yet, we would
> require for now that when SOURCE or DEST are remote, they must refer
> to the same repository.
This should be doable. The above command would be a single COPY request over
the network.
Now... I do have to say that we aren't going to be close to that point for a
good while. Within the framework of DAV, a COPY on a versioned collection
implies auto-versioning. For the moment, I'm avoiding that big time, and
wrapping all changes into a DAV "activity". An activity corresponds to an FS
"transaction". So... to do autoversioning, the server is going to have a
good chunk of work. Before we get there, I would imagine the client would
transform the above command into a sequence of MKACTIVITY, CHECKOUT
<parent-of-DEST>, COPY <SOURCE> to <DEST>, MERGE <activity>.
But... neither here nor there. Within the DAV framework, the above command
is totally fine from a semantic standpoint and we can/will be able to
support it at some point [for 1.0? post 1.0? hard to say... my pragmatism
wants to cut auto-versioning for SVN 1.0.. but we can do the long route via
activities, surely]
What does this mean? There are a *lot* of things that we can do without a
working copy. In fact, the DAV model is designed to operate *without* a
local copy. The DeltaV guys have had a few re-thinks based on our local,
working copy model.
Theoretically, all the data that is kept in the SVN subdir (except for the
"entries" file) could be stored on the server as part of a user's
"workspace". Any kind of operation imaginable on the local copy is doable on
the server, provided we support *enough* of the complete DAV model.
Keyword: "enough". mod_dav_svn 1.0 (the guts of our DAV support on the
server) will support what Subversion *needs*. We won't be a true and
complete DeltaV server. Well, I shouldn't say that... maybe there will be
time to build more in there, but my focus is on a DeltaV subset at this
point. When that is DONE, then we can look at becoming a true and proper
DeltaV server.
etc etc.
Cheers,
-g
--
Greg Stein, http://www.lyra.org/
Re: cmd line stuff (was: CVS update: ...)
Posted by Jim Blandy <ji...@savonarola.red-bean.com>.
I've added my old command-line notes to subversion/client/README. Here
are the ideas I thought were worthwhile:
* It seems kind of archaic to type:
svn -d REPO-SPEC checkout MODULE
This splits the information `what am I checking out' across two
different places. It would be nicer to simply name the thing you're
checking out, using some appropriate noun clause. For remote things,
URL's are the natural kind of noun clause:
svn checkout http://subversion.tigris.org/repo/subversion
I don't know if this is exactly the DAV way; maybe Greg can provide a
more realistic example. But the important idea is that the syntax
should be:
svn checkout THING
* Given Subversion's idea that the repository is just a versioned
filesystem, it makes sense to allow some operations directly on the
repository. For example, if I want to copy a tree, so I can start
work on a separate branch of development, I shouldn't have to check
out this huge tree, copy a big section of it, and then commit that.
Just as I can say:
svn cp SOURCE DEST
to copy something in my working directory, I should be able to use
URL's for SOURCE and / or DEST, and have the right thing happen. It's
the same idea behind rcp / scp: instead of providing one command for
downloading, and a separate command for uploading, just provide a
syntax for referring to files elsewhere, and let the names tell you
how the data needs to flow.
Since we don't support inter-repository branching yet, we would
require for now that when SOURCE or DEST are remote, they must refer
to the same repository.
Re: cmd line stuff (was: CVS update: ...)
Posted by Lee Burgess <le...@red-bean.com>.
B. W. Fitzpatrick writes:
> > Okay:
> >
> > 1. "export" command, yes.
> >
> > 2. "export" command requiring date or version option, please no.
> > It is not Subversion's place to enforce good CM policy, when
> > such enforcement would obstruct other perfectly reasonable uses
> > of Subversion. A good release engineer will pass the flag, a
> > bad one won't. That's fine, let's just please not make it
> > impossible for there to be other uses of "export". (And for the
> > record, I *do* have other uses for export very often in CVS, and
> > am forced to pass "export -D tomorrow" to get the behavior I
> > need.)
>
> I would like to second this as it has bitten me in the past. Of
> course, now CVS and I are old friends and I remember to pass it a tag
> or '-D tomorrow' or whatnot.
>
> -Fitz
+1
--
Lee P. W. Burgess <<!>> Manipulate eternity. Power is a symphony:
Programmer <<!>> elaborate, enormous, essential.
Red Bean Software <<!>> Dream the moment with a fiddle in summer
lefty@red-bean.com <<!>> and a knife in winter.
Re: cmd line stuff (was: CVS update: ...)
Posted by Karl Fogel <kf...@galois.collab.net>.
Branko =?iso-8859-2?Q?=C8ibej?= <br...@xbc.nu> writes:
> Hmm, hmm, hmm. Your argument has merit. There's also the old adage
> about foolproof programs.
>
> I'd be quite happy if we could "promise" that someday it'll be possible
> to write a script on the SVN server side to, e.g., reject an export
> if an explicit tag wasn't supplied; or reject a commit if there were
> merge conflicts; etc., etc. Then all of this boils down to putting
> examples into contrib/ (once we have it).
The latter is certainly possible -- just a server-side hook script.
The former is harder, because all requests for trees have a specific
version attached anyway. But I can see various other ways to get
protection nonetheless, if someone wants to enforce it for their site.
I think it won't be a problem.
Re: cmd line stuff (was: CVS update: ...)
Posted by Branko Čibej <br...@xbc.nu>.
Karl Fogel wrote:
> 2. "export" command requiring date or version option, please no.
> It is not Subversion's place to enforce good CM policy, when
> such enforcement would obstruct other perfectly reasonable uses
> of Subversion. A good release engineer will pass the flag, a
> bad one won't.
Hmm, hmm, hmm. Your argument has merit. There's also the old adage
about foolproof programs.
I'd be quite happy if we could "promise" that someday it'll be possible
to write a script on the SVN server side to, e.g., reject an export
if an explicit tag wasn't supplied; or reject a commit if there were
merge conflicts; etc., etc. Then all of this boils down to putting
examples into contrib/ (once we have it).
--
Brane �ibej
home: <br...@xbc.nu> http://www.xbc.nu/brane/
ACM: <br...@acm.org> http://www.acm.org/
Re: cmd line stuff (was: CVS update: ...)
Posted by Karl Fogel <kf...@galois.collab.net>.
Okay:
1. "export" command, yes.
2. "export" command requiring date or version option, please no.
It is not Subversion's place to enforce good CM policy, when
such enforcement would obstruct other perfectly reasonable uses
of Subversion. A good release engineer will pass the flag, a
bad one won't. That's fine, let's just please not make it
impossible for there to be other uses of "export". (And for the
record, I *do* have other uses for export very often in CVS, and
am forced to pass "export -D tomorrow" to get the behavior I
need.)
-K
Branko Cibej <br...@xbc.nu> writes:
> > Well, it's easy to implement, so no harm in adding it if people want
> > it. Just let's *please* not require a -r or -D flag like CVS does. :-)
> >
>
> Putting my "Project CM Engineer" hat on:
>
> Yes, it's necessary; and yes, I want to make sure any distro I make
> has a corresponding tag in the repository. And when I'm testing the
> distribution procedures/scripts, I can always trick CVS with a
> `-D today', hehe. :-)
>
> --
> Brane Cibej
> home: <br...@xbc.nu> http://www.xbc.nu/brane/
> ACM: <br...@acm.org> http://www.acm.org/
Re: cmd line stuff (was: CVS update: ...)
Posted by Branko Cibej <br...@xbc.nu>.
Karl Fogel wrote:
> Is it really necessary?
>
> Well, it's easy to implement, so no harm in adding it if people want
> it. Just let's *please* not require a -r or -D flag like CVS does. :-)
>
Putting my "Project CM Engineer" hat on:
Yes, it's necessary; and yes, I want to make sure any distro I make
has a corresponding tag in the repository. And when I'm testing the
distribution procedures/scripts, I can always trick CVS with a
`-D today', hehe. :-)
--
Brane Cibej
home: <br...@xbc.nu> http://www.xbc.nu/brane/
ACM: <br...@acm.org> http://www.acm.org/
Re: cmd line stuff (was: CVS update: ...)
Posted by Karl Fogel <kf...@galois.collab.net>.
Greg Stein <gs...@lyra.org> writes:
> > +A start on global options:
> > +
> > + -r repository Use REPOSITORY.
>
> Wouldn't this be an argument to the checkout command? Or are we planning to
> allow some of the commands when a working copy does not exist? e.g. why
> specify the repository for an "update" ?
Good question.
It's an issue of how many commands could work without a working copy
available. Some are:
import
checkout
rdiff
copy/branch/tag (questionable wisdom, maybe)
annotate
So that's more than three, anyway... makes me think it *maybe* should
be a global option (partially I'm swayed by the fact that this keeps
us consistent with CVS). But not sure. Thoughts?
> what the heck is rdiff?
Like cvs diff but you don't need a working copy.
> > + annotate | ann
> > + import | im | imp
>
> export?
Is it really necessary?
Well, it's easy to implement, so no harm in adding it if people want
it. Just let's *please* not require a -r or -D flag like CVS does. :-)
> > + history | hi | his
> > + log | lo
>
> how are history and log different?
Sorry, history was a typo; I've removed it. Just meant to say log.
> Will we have a "login" command? A URL can specify a user/password, but I'm
> sure many people will want prompts to keep the pwd off the cmd line.
>
> Speaking of: I think we can skip that whole "munge the pwd before storing in
> .cvspass" is bogus. Just store it in clear text and chmod the file properly.
> The cmd line should abort operation if the perms on that file are incorrect
> ("your .svnrc file has incorrect permissions, please set to 0600" or
> whatever).
>
> Along a similar line, there are going to be different ways to authenticate
> with the server. Sometimes, we may not even have a password :-) Other times,
> we need to somehow figure out where a client-side certificate is stored.
Yeah, this is a complex issue. I haven't really thought it through
carefully.
CVS's scrambling is questionable but not entirely crazy. I'd like to
know what other people think, but yeah, it's costs and benefits do
balance out pretty closely (and both are pretty minor).
> > +Some command-specific options are unique to that command, but others
> > +are common to several commands, for example:
> > +
> > + -v version Like "cvs cmd -r REV"
>
> urk. Is it possible to avoid duplicate letters between the global and local
> options? Dunno how much people confuse them, but it might be a nice start.
Erm, hmm. Well, yes, but only at the cost of losing a lot of the
optionspace.
CVS duplicates some options, and people don't seem to have a problem
in practice (not just myself -- I don't recall ever seeing someone get
confused about that in my bygone days as a CVS troubleshooter).
Re: cmd line stuff (was: CVS update: ...)
Posted by Greg Stein <gs...@lyra.org>.
Not to mention:
$ alias vsvn="svn -v"
$ vsvn co ...
Cheers,
-g
On Wed, Oct 18, 2000 at 12:17:04PM -0500, Karl Fogel wrote:
> Sorry -- I agreed too fast with the original post, and am now agreeing
> (more slowly and thoughtfully) with Jonathan's refutation of it.
>
> He's right, we should be standard if we can. Also, it's very
> convenient to allow options and arguments mixed -- that way if you
> forgot something, you can just type it wherever you are and not worry.
>
> "Jonathan S. Shapiro" <sh...@eros-os.org> writes:
> > > Good. It should also, then, be okay to require that all
> > > options appear after the subcommand name. Viz.:
> > >
> > > svn <subcommand> [ <option> ... ] [ <arg> ...]
> > >
> > > Yes?
> >
> > NO. There is an existing standard command processing interface. It is called
> > getopts(). It specifically (and by design) does *not* require that options
> > appear before arguments.
> >
> > The existing standard may be stupid, but it is widely well understood and it
> > isn't ugly. Unless there is a really *really* compelling reason to discard
> > it, don't do so.
> >
> > It took fifteen bloody years to *regularize* the UNIX command interface!
> >
> > shap
--
Greg Stein, http://www.lyra.org/
Re: cmd line stuff (was: CVS update: ...)
Posted by Karl Fogel <kf...@galois.collab.net>.
Sorry -- I agreed too fast with the original post, and am now agreeing
(more slowly and thoughtfully) with Jonathan's refutation of it.
He's right, we should be standard if we can. Also, it's very
convenient to allow options and arguments mixed -- that way if you
forgot something, you can just type it wherever you are and not worry.
"Jonathan S. Shapiro" <sh...@eros-os.org> writes:
> > Good. It should also, then, be okay to require that all
> > options appear after the subcommand name. Viz.:
> >
> > svn <subcommand> [ <option> ... ] [ <arg> ...]
> >
> > Yes?
>
> NO. There is an existing standard command processing interface. It is called
> getopts(). It specifically (and by design) does *not* require that options
> appear before arguments.
>
> The existing standard may be stupid, but it is widely well understood and it
> isn't ugly. Unless there is a really *really* compelling reason to discard
> it, don't do so.
>
> It took fifteen bloody years to *regularize* the UNIX command interface!
>
> shap
Re: cmd line stuff (was: CVS update: ...)
Posted by "Jonathan S. Shapiro" <sh...@eros-os.org>.
> Good. It should also, then, be okay to require that all
> options appear after the subcommand name. Viz.:
>
> svn <subcommand> [ <option> ... ] [ <arg> ...]
>
> Yes?
NO. There is an existing standard command processing interface. It is called
getopts(). It specifically (and by design) does *not* require that options
appear before arguments.
The existing standard may be stupid, but it is widely well understood and it
isn't ugly. Unless there is a really *really* compelling reason to discard
it, don't do so.
It took fifteen bloody years to *regularize* the UNIX command interface!
shap
Re: cmd line stuff (was: CVS update: ...)
Posted by Bruce Korb <bk...@sco.COM>.
Karl Fogel wrote:
>
> No, I think Jonathan wasn't arguing with the idea that the command
> comes before any options or arguments. The command is neither an
> option nor an argument. In other words:
>
> svn [<command>] [<option|argument> ...]
He has to answer that. It was not the way I read him, though.
> Re: Greg Hudson's point that there are a couple of different standards
> here: I rolled on the floor laughing and crying at the same time. :-)
It is what I have always liked about standards, too. ;-)
> But seriously, I think we should (eventually if not immediately)
> support the more flexible GNU way, because it does result in increased
> convenience for the user, and is no more ambiguous than the other way.
> [By the way, CVS, to my surprise, requires that the command options
> come before command arguments.]
That *is* according to the POSIX command line standard.
Long option names are not according to that standard,
which is one big reason why adherence is, well, lax.
Standardization via committee has its hazards....
Cheers,
Bruce
Re: cmd line stuff (was: CVS update: ...)
Posted by Karl Fogel <kf...@galois.collab.net>.
Bruce Korb <bk...@sco.COM> writes:
> Good. It should also, then, be okay to require that all
> options appear after the subcommand name. Viz.:
>
> svn <subcommand> [ <option> ... ] [ <arg> ...]
>
> Yes?
That's what it says. :-)
Re: cmd line stuff (was: CVS update: ...)
Posted by Greg Stein <gs...@lyra.org>.
On Wed, Oct 18, 2000 at 03:44:15PM -0400, Greg Hudson wrote:
> > Way too hard. ``svn'' + ``<subcommand>'' is the command.
>
> Perhaps we should reconsider whether we want a single command with
> subcommands in the first place. Why "svn commit" intead of
> "svncommit"? The only real advantage to the former is a cleanliness
> issue for aliases (e.g. we'd have to either sacrifice "svnci" as an
> alias for "svncommit", or put a symlink svnci -> svncommit; if we go
> the symlink route, our contribution to the number of entries in the
> binary directory becomes absurd).
>
> In CVS, of course, the main advantage of a single command was code
> sharing. But that's what libraries are for, and this project is
> definitely big on libraries already.
>
> Well, just a thought. I don't have a strong opinion one way or the
> other.
Urk. um.... "no way" :-)
I would rather not have a bazillion binaries (or hard/soft links to a single
binary) laying around my filesystem. Or needing to install Yet Another SVN
Command Binary when we come up with something else.
Having them in a single binary also makes it a tad easier to keep your
"help" in order. It is much easier for somebody to do "svn help" than to
struggle through man/info pages to figure out what the hell the name of the
binary is that they're looking for.
Cheers,
-g
--
Greg Stein, http://www.lyra.org/
Re: cmd line stuff (was: CVS update: ...)
Posted by Greg Stein <gs...@lyra.org>.
On Wed, Oct 18, 2000 at 04:17:57PM -0400, Greg Hudson wrote:
> > But seriously, I think we should (eventually if not immediately)
> > support the more flexible GNU way, because it does result in
> > increased convenience for the user, and is no more ambiguous than
> > the other way.
>
> Well, there are some implementation issues:
>
> * gnu getopt supports the more flexible way, but apr_getopt()
> does not (and the BSD implementation does not). I don't
> know how the APR people would feel about making apr_getopt()
> more flexible. apr_getopt_long() needs to be consistent
> with apr_getopt().
If the code is provided, then I'll check it in! :-) I don't believe there
would be any objections. [presuming it isn't a massive implementation
across a dozen files]
> Of course, this point is moot if we use autoopt. I'm not
> quite sure where that decision lies; Bruce Korb and company
> seem very gung-ho about it,
I'm not sure that Bruce ever made a disclaimer: he is the author of AutoOpt.
So yes... I now understand his gung-ho-ness, and his response about
"notifying the author".
> but several of the people who have
> previously done work on Subversion expressed reservations
> about bringing in a separate external tool for such a small
> problem. If we do use autoopt, then we can only support the
> more flexible approach if autoopt does.
I'm -0 on bringing in AutoOpt. I'd much rather see our option performed
using getopts() [or its variants using whatever codebase we can]
Consider: why are we using Autoconf, Automake, and Libtool? Because the
tools are great? Don't make me laugh. No... we use them because *other*
people know them, and those others can then usefully contribute to our auto*
setup.
Why use getopts()? Because other people know them, and we can leverage that
group knowledge.
Cheers,
-g
--
Greg Stein, http://www.lyra.org/
Re: cmd line stuff (was: CVS update: ...)
Posted by Karl Fogel <kf...@galois.collab.net>.
No, I think Jonathan wasn't arguing with the idea that the command
comes before any options or arguments. The command is neither an
option nor an argument. In other words:
svn [<command>] [<option|argument> ...]
Re: Greg Hudson's point that there are a couple of different standards
here: I rolled on the floor laughing and crying at the same time. :-)
But seriously, I think we should (eventually if not immediately)
support the more flexible GNU way, because it does result in increased
convenience for the user, and is no more ambiguous than the other way.
[By the way, CVS, to my surprise, requires that the command options
come before command arguments.]
-K
Bruce Korb <bk...@sco.COM> writes:
> That leaves you with a rather interesting dilemma:
>
> svn -x foo bar
>
> Which is the subcommand, "foo" or "bar"?
> Well, it depends. For the "foo" subcommand, -x happens to
> require an argument, but for the "bar" subcommand, it does
> not. Or, was that the other way around? In any event,
> without knowing which is the subcommand, you cannot know
> how to handle the -x flag option. Unless, of course, all
> options apply to all subcommands and the subcommand processing
> code has to figure out what happened. To this, *I* say, "No." :-)
> Way too hard. ``svn'' + ``<subcommand>'' is the command.
> Or, rather, ``<subcommand>'' is the command within the svn's
> command name space, if you like.
>
> - Bruce
Re: cmd line stuff (was: CVS update: ...)
Posted by Greg Stein <gs...@lyra.org>.
On Wed, Oct 18, 2000 at 12:40:25PM -0700, Bruce Korb wrote:
>...
> That leaves you with a rather interesting dilemma:
>
> svn -x foo bar
>
> Which is the subcommand, "foo" or "bar"?
> Well, it depends. For the "foo" subcommand, -x happens to
> require an argument, but for the "bar" subcommand, it does
> not. Or, was that the other way around? In any event,
> without knowing which is the subcommand, you cannot know
> how to handle the -x flag option. Unless, of course, all
> options apply to all subcommands and the subcommand processing
> code has to figure out what happened. To this, *I* say, "No." :-)
> Way too hard. ``svn'' + ``<subcommand>'' is the command.
> Or, rather, ``<subcommand>'' is the command within the svn's
> command name space, if you like.
Oh, this is an easy one:
1) you cannot specify two subcommands at one time.
2) the -x is not processed until *after* the entire argv is parsed. The
first thing after parsing is to look for the subcommand.
Cheers,
-g
--
Greg Stein, http://www.lyra.org/
Re: cmd line stuff (was: CVS update: ...)
Posted by pohl <po...@screaming.org>.
> Bruce Korb wrote:
>
> > That leaves you with a rather interesting dilemma:
> >
> > svn -x foo bar
> >
> > Which is the subcommand, "foo" or "bar"?
> > Well, it depends. For the "foo" subcommand, -x happens to
> > require an argument, but for the "bar" subcommand, it does
> > not.
>
> This is completely buggered. Either -x takes an argument in all
> cases or it takes no argument in all cases.
I think you're right, but I believe Bruce meant to use "-x"
as a metasyntactic option, in which case we don't know which
flavor it is & therefore can only answer in a case-by-case
manner.
----
pohl@screaming.org
Re: cmd line stuff (was: CVS update: ...)
Posted by "Jonathan S. Shapiro" <sh...@cs.jhu.edu>.
Bruce Korb wrote:
> That leaves you with a rather interesting dilemma:
>
> svn -x foo bar
>
> Which is the subcommand, "foo" or "bar"?
> Well, it depends. For the "foo" subcommand, -x happens to
> require an argument, but for the "bar" subcommand, it does
> not. Or, was that the other way around? In any event,
> without knowing which is the subcommand, you cannot know
> how to handle the -x flag option.
This is completely buggered. Either -x takes an argument in all cases or it takes
no argument in all cases. Having the behavior of the option be conditional on the
command violates every option convention I can remember from anywhere. The
correct answer to the problem you pose is to have a consistent set of options in
the first place.
This sort of thing is part of why I think it's a bad idea to incorporate the
legacy command interface directly into SVN. We gotta be compatible for some
folks, but let's keep the cruft all in one place where we can shoot it all at
once later.
Oh: on the svn command echo thing: There should be an alternative script name
(qcvscompat vs. cvscompat) that doesn't do this so that existing batch scripts
can use the command translator without seeing unexpected output. It can't be a
new type of quiet option because there will prove to be scripts that do:
cvs = getenv("CVS")
exec(cvs, args, ...)
and if exec is passed
exec("cvscompat.pl -nontutorial", argcount, argvec)
it will barf.
shap
Re: cmd line stuff (was: CVS update: ...)
Posted by Bruce Korb <bk...@sco.COM>.
"Jonathan S. Shapiro" wrote:
>
> > Good. It should also, then, be okay to require that all
> > options appear after the subcommand name. Viz.:
> >
> > svn <subcommand> [ <option> ... ] [ <arg> ...]
> >
> > Yes?
>
> NO. There is an existing standard command processing interface. It is called
> getopts(). It specifically (and by design) does *not* require that options
> appear before arguments.
>
> The existing standard may be stupid, but it is widely well understood and it
> isn't ugly. Unless there is a really *really* compelling reason to discard
> it, don't do so.
>
> It took fifteen bloody years to *regularize* the UNIX command interface!
That leaves you with a rather interesting dilemma:
svn -x foo bar
Which is the subcommand, "foo" or "bar"?
Well, it depends. For the "foo" subcommand, -x happens to
require an argument, but for the "bar" subcommand, it does
not. Or, was that the other way around? In any event,
without knowing which is the subcommand, you cannot know
how to handle the -x flag option. Unless, of course, all
options apply to all subcommands and the subcommand processing
code has to figure out what happened. To this, *I* say, "No." :-)
Way too hard. ``svn'' + ``<subcommand>'' is the command.
Or, rather, ``<subcommand>'' is the command within the svn's
command name space, if you like.
- Bruce
Re: cmd line stuff (was: CVS update: ...)
Posted by "Jonathan S. Shapiro" <sh...@cs.jhu.edu>.
I'm not interested in joining a standards war. If people like the
GNU getopts_long() style, that seems fine to me.
I *would* appreciate it if we could avoid confusing people who are already
well trained on the POSIX standard. If the command as typed follows that
standard it should work.
Re: cmd line stuff (was: CVS update: ...)
Posted by Bruce Korb <bk...@sco.COM>.
Karl Fogel wrote:
>
> Sorry -- I agreed too fast with the original post, and am now agreeing
> (more slowly and thoughtfully) with Jonathan's refutation of it.
>
> He's right, we should be standard if we can. Also, it's very
> convenient to allow options and arguments mixed -- that way if you
> forgot something, you can just type it wherever you are and not worry.
Well, the standard also disallows intermixing.
Also, I do think it depends on how you conceptualize the command line.
IF `svn' is considered a shell (which is the way the discussion
seems to be leading), THEN what follows on the line is a command
and its options and arguments. The command and its opts & args *does*
follow the convention^H^H^H^Hstandard. :-)
Re: cmd line stuff (was: CVS update: ...)
Posted by Bruce Korb <bk...@sco.COM>.
Karl Fogel wrote:
>
> It seems there is widespread agreement that having two namespaces for
> options, one global and one command-local, is a bad idea. I've
> updated client/README accordingly.
Good. It should also, then, be okay to require that all
options appear after the subcommand name. Viz.:
svn <subcommand> [ <option> ... ] [ <arg> ...]
Yes?
Re: cmd line stuff (was: CVS update: ...)
Posted by Karl Fogel <kf...@galois.collab.net>.
It seems there is widespread agreement that having two namespaces for
options, one global and one command-local, is a bad idea. I've
updated client/README accordingly.
-K
RADICS Peter <mi...@deneb.lbcons.net> writes:
> On Tue, Oct 17, 2000 at 01:02:44PM -0700, Matthew Braithwaite wrote:
> [SNIP]
> > Sure -- Karl's statement that -d does in fact cause confusion is absolutely
> > sufficient reason to change it. Until this moment I had no idea that there
> [SNIP]
>
> How about using -R for repository (instead of -d as in CVS). -r is used
> a lot in CVS, so changing that is not a good idea, but -R is almost
> never used, since it's the same as the default behaviour (recursive).
>
> And I also support the idea of not having "global" and "command local"
> options, that's why -r and -r clash. uhm. whatever. :)
>
> cheers,
> mitch
> --
> // RADICS Peter <mi...@lbcons.net> (http://lbcons.net)
> //
> // "If human beings don't keep exercising their lips,
> // their brains start working." -- Ford Prefect
Re: cmd line stuff (was: CVS update: ...)
Posted by Bruce Korb <bk...@sco.COM>.
RADICS Peter wrote:
>
> On Tue, Oct 17, 2000 at 01:02:44PM -0700, Matthew Braithwaite wrote:
> [SNIP]
> > Sure -- Karl's statement that -d does in fact cause confusion is absolutely
> > sufficient reason to change it. Until this moment I had no idea that there
> [SNIP]
>
> How about using -R for repository (instead of -d as in CVS). -r is used
> a lot in CVS, so changing that is not a good idea, but -R is almost
> never used, since it's the same as the default behaviour (recursive).
OK. I confess. I already did that for my fluff-man proposal
that is coming out RSN. So, it is not really a completely faithful
copy of the CVS options. :-). Just mostly so because there are
almost 170 options specified for CVS. But then, I haven't recounted
after combining most of the duplicates. And there are still a few
more to combine, too. Fluffman will consist of only unique options.
- Bruce
Re: cmd line stuff (was: CVS update: ...)
Posted by RADICS Peter <mi...@deneb.lbcons.net>.
On Tue, Oct 17, 2000 at 01:02:44PM -0700, Matthew Braithwaite wrote:
[SNIP]
> Sure -- Karl's statement that -d does in fact cause confusion is absolutely
> sufficient reason to change it. Until this moment I had no idea that there
[SNIP]
How about using -R for repository (instead of -d as in CVS). -r is used
a lot in CVS, so changing that is not a good idea, but -R is almost
never used, since it's the same as the default behaviour (recursive).
And I also support the idea of not having "global" and "command local"
options, that's why -r and -r clash. uhm. whatever. :)
cheers,
mitch
--
// RADICS Peter <mi...@lbcons.net> (http://lbcons.net)
//
// "If human beings don't keep exercising their lips,
// their brains start working." -- Ford Prefect
Re: cmd line stuff (was: CVS update: ...)
Posted by Matthew Braithwaite <ma...@braithwaite.net>.
On Tue, Oct 17, 2000 at 11:39:20AM -0500, B. W. Fitzpatrick wrote:
> > -d is a historical leftover even in CVS, from the days when the
> > repository was always a directory on the same machine as the working
> > copy.
> >
> > I don't think we should try to preserve CVS's hysterical raisins --
> > that's needlessly perpetuating confusion
>
> That should, IMO, be the charter of the command line client
> group. Many of the letters for CVS's command line options make
> absolutely no sense. Let's hear it for `Feature Compatible' with CVS,
> not `Just as buggy and weird as' CVS.
Sure -- Karl's statement that -d does in fact cause confusion is absolutely
sufficient reason to change it. Until this moment I had no idea that there
were people who had trouble simply memorizing this stuff. This is probably
a positive proof that you shouldn't put me in charge of user-friendliness (as
though one were needed).
Hey Fitz, I don't need to be scared of Lefty, do I? :-)
Re: cmd line stuff (was: CVS update: ...)
Posted by Karl Fogel <kf...@galois.collab.net>.
Matthew Braithwaite <ma...@braithwaite.net> writes:
> Speaking of historical reasons, the change from -d to -r seems a little bit
> gratuitous to me. Does -d count as ``suffocatingly'' similar to CVS? :-)
-d is a historical leftover even in CVS, from the days when the
repository was always a directory on the same machine as the working
copy.
I don't think we should try to preserve CVS's hysterical raisins --
that's needlessly perpetuating confusion (and people *do* get confused
about the -d flag, since the two commonly-used names for the
repository both begin with `r': "repository" and "root").
People may have to think twice at first, but once they get used to it,
it's a better option.
I hope this falls under the last clause in this paragraph from
subversion/subversion/client/README:
We're trying to be similar to command-line CVS, but not
suffocatingly so. Subversion will differ where it provides a
feature CVS doesn't, or doesn't provide something CVS does, or
where people generally agree that the CVS way is not successful and
shouldn't be imitated.
Re: cmd line stuff (was: CVS update: ...)
Posted by Matthew Braithwaite <ma...@braithwaite.net>.
On Tue, Oct 17, 2000 at 06:55:21AM -0500, B. W. Fitzpatrick wrote:
> > On Tue, Oct 17, 2000 at 12:05:49AM -0000, kfogel@tigris.org wrote:
> > >...
> > > +A start on global options:
> > > +
> > > + -r repository Use REPOSITORY.
> >
> > Wouldn't this be an argument to the checkout command? Or are we planning to
> > allow some of the commands when a working copy does not exist? e.g. why
> > specify the repository for an "update" ?
>
> I would guess that it's for hysterical raisins. I mean, how many times
> have you done this:
>
> $ cvs -d :pserver:foo@bar.com:/cvs login
> $ cvs -d :pserver:foo@bar.com:/cvs co qux
Well, not only that -- at least under CVS, I frequently have to use a
repository other than the one encoded in CVS/ for some bletcherous reason
or other. For example, the repository used to be local, but somebody moved
it to another machine. So CVS/Root says `/src', and I have to say
`cvs -d mab@cvs:/src diff ...' to get useful results. So it's kinda handy
to have it be a global option.
Speaking of historical reasons, the change from -d to -r seems a little bit
gratuitous to me. Does -d count as ``suffocatingly'' similar to CVS? :-)
Re: cmd line stuff (was: CVS update: ...)
Posted by Greg Stein <gs...@lyra.org>.
I was about to say... but Joe beat me to it :-)
On Tue, Oct 17, 2000 at 09:06:17AM +0100, Joe Orton wrote:
> On Tue, Oct 17, 2000 at 09:24:53AM +0200, Daniel Stenberg wrote:
> > This got me thinking. Has there any thoughts around encrypted svn
> > connections?
>
> I had the DAV tester do a checkout over SSL a few weeks ago :) Compile
> SSL support into neon (configure --with-ssl=/wherever), and pass the DAV
> tester thingy an https: URL, and you're away.
You know. That is just *too* easy. Damn... what is going on around here!?
hehe...
> (there is no SSL support for Apache 2 yet though)
The ASF is consulting a lawyer as we speak. The question at hand is whether
we would have problems placing SSL code into the mainline distribution. The
general presumption is "no problem", but we are getting legal counsel first.
Of course, there are a number of SSL versions of Apache out there, including
the one published by Joe's company (was C2Net, now Redhat). Free stuff is
available thru mod_ssl or ApacheSSL.
Cheers,
-g
--
Greg Stein, http://www.lyra.org/
Re: cmd line stuff (was: CVS update: ...)
Posted by Joe Orton <jo...@light.plus.com>.
On Tue, Oct 17, 2000 at 09:24:53AM +0200, Daniel Stenberg wrote:
> This got me thinking. Has there any thoughts around encrypted svn
> connections?
I had the DAV tester do a checkout over SSL a few weeks ago :) Compile
SSL support into neon (configure --with-ssl=/wherever), and pass the DAV
tester thingy an https: URL, and you're away.
(there is no SSL support for Apache 2 yet though)
joe
Re: cmd line stuff (was: CVS update: ...)
Posted by Karl Fogel <kf...@galois.collab.net>.
Daniel Stenberg <da...@haxx.se> writes:
> I'm in favour for verbose as well.
How about --verbose and -V, for that.
Re: cmd line stuff (was: CVS update: ...)
Posted by Daniel Stenberg <da...@haxx.se>.
On Tue, 17 Oct 2000, Greg Stein wrote:
> > + -v --version Print program name, version, and url.
>
> -v for verbose? Will we have a verbose option? [and version would be -V]
I'm in favour for verbose as well.
> what the heck is rdiff?
(quote from the CVS man page)
rdiff
Prepare a collection of diffs as a patch file between
two releases in the repository. (Does not change repo-
sitory or working directory.)
It's a massive diff on all the files in the respository.
> Along a similar line, there are going to be different ways to
> authenticate with the server. Sometimes, we may not even have a password
> :-) Other times, we need to somehow figure out where a client-side
> certificate is stored.
This got me thinking. Has there any thoughts around encrypted svn
connections? Would that be based on SSL then for easiest possible integration
with apache?
--
Daniel Stenberg - http://daniel.haxx.se - +46-705-44 31 77
ech`echo xiun|tr nu oc|sed 'sx\([sx]\)\([xoi]\)xo un\2\1 is xg'`ol