[getopt-sig] commands on the command line
Greg Ward
gward@python.net
Thu, 7 Mar 2002 12:30:44 -0500
On 04 March 2002, Matthias Urlichs said:
> Personally, I fail to have a problem with
>
> - parse global options with one instance of an option parser
> - interpret the first non-option as command (assuming that options and
> arguments are Not To Be Interspersed)
> - parse command's options with another, different parser instance
>
> so frankly I don't see the point of your code..?
I completely agree with Matthias. In fact, I posted pseudo-code for how
to do precisely this with Optik a few weeks ago.
Furthermore, this is a pretty arcane special case; the only obvious
examples I can think of offhand are CVS and the Distutils. If I can't
rewrite the Distutils' command-line processing with whatever comes out
of this SIG, then this will have been a big fat waste of time, but I
certainly don't think Optik (or whatever) needs to directly accomodate
this somewhat unusual syntax.
Greg
--
Greg Ward - Linux weenie gward@python.net
http://starship.python.net/~gward/
What happens if you touch these two wires tog--