In <[EMAIL PROTECTED]>, Frans Englich
wrote:

>> > In my use of getopt.getopt, I would like to make a certain parameter
>> > mandatory.
>>
>> Isn't a *mandatory option* a contradiction?  Why don't you turn it into an
>> argument?  You already called it argument in the subject of your post.
> 
> I probably used an inconsisten wording; option equals argument. My point is 
> to 
> make an option/parameter/argument/call-it-what-you-like mandatory. When that 
> particular option/argument then also has a value(instead of a simple toggle), 
> that means a user specified value must always be specified.

I had the following in mind:

  http://www.python.org/doc/2.4/lib/optparse-what-options-for.html

Although the optparse documentation discourages `required options` there
are two examples in the source distribution how to implement them with the
optparse module.

Ciao,
        Marc 'BlackJack' Rintsch
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to