Library for handling GNU parameters
David Goodger
goodger at python.org
Mon Feb 23 21:37:08 EST 2004
François Pinard wrote:
> I think I read that `optparse' is not going to handle optional
> arguments that we find in some commands,
Do you mean "optional option arguments"? Where an option has an
optional argument? I believe this idea was discussed on the
optik-users list, but it was determined that such a thing is not
reliably parseable.
> and which GNU `getopt' (and also the old
> standard `getopt', if I remember well) do handle.
getopt.py does *not* handle "optional option arguments" either.
If you meant optional positional arguments, optparse and getopt both
support them (by leaving the logic up to the client program).
-- David Goodger
More information about the Python-list
mailing list