Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Python > Print Options of optparse

Reply
Thread Tools

Print Options of optparse

 
 
Enchanter
Guest
Posts: n/a
 
      12-17-2009
I am learning Python and uising optparse to handle command-line
options. But I am not sure who to print the options' content below:

......

options, args = parser.parse_args()

 
Reply With Quote
 
 
 
 
Steven D'Aprano
Guest
Posts: n/a
 
      12-17-2009
On Wed, 16 Dec 2009 23:10:26 -0800, Enchanter wrote:

> I am learning Python and uising optparse to handle command-line options.
> But I am not sure who to print the options' content below:
>
> .....
>
> options, args = parser.parse_args()



Is there a reason why

print options


doesn't do what you want?




--
Steven
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Re: optparse - required options Omari Norman Python 2 08-24-2007 03:56 AM
getopt or optparse options/arguments wrapping? Rocky Zhou Python 3 03-18-2007 07:45 PM
optparse and counting arguments (not options) Steven Bethard Python 0 05-10-2006 04:33 AM
Required options in optparse Gregory (Grisha) Trubetskoy Python 0 10-04-2003 01:31 AM
Re: Iterating over optparse options David Goodger Python 0 06-25-2003 01:46 PM



Advertisments