Re: The bake-off
David Boddie <[email protected]> Thu, 30 May 2002 13:50:15 +0100
| Newsgroups | gmane.comp.python.getopt |
|---|---|
| Organization | SleepyDog |
| Message-ID | <[email protected]> |
On Thursday 30 May 2002 1:22 pm, Guido van Rossum wrote: > > There was some discussion about the use of conflicting options, > > resulting from the practice of aliasing commands. Whether things > > like "--verbose --quiet" were allowable proved to be a point of > > contention. > > Hm, obviously the last option wins; it's a common trick to alias a > command to specify a bunch of default options, and it's useful to > override those explicitly by adding more options to the alias > invocation. So, do you consider that the rightmost options always take precedence over others? An alternative viewpoint can be found here: http://mail.python.org/pipermail/getopt-sig/2002-February/000097.html I would consider something like an --override option would be useful for requesting that any previous options (possibly supplied by an alias) be ignored in favour of new ones added at the command line. e.g. mycommand --quiet --override --verbose However, I'm not sure that this is the most appropriate time to suggest such a feature, given that we've extensively debated this in the past. My suggestion doesn't allow individual options to be overridden, either. > > Do you want to see implementations of mechanisms for validating > > types and resolving option conflicts as well? > > If you think it helps, sure. It might make the playing field more level. David ________________________________________________________________________ This email has been scanned for all viruses by the MessageLabs SkyScan service. For more information on a proactive anti-virus service working around the clock, around the globe, visit http://www.messagelabs.com ________________________________________________________________________