Duncan Booth wrote: >>>> from optparse import OptionParser >>>> usage = "usage: %prog [options] arg1 arg2" >>>> epilog = "that's all folks!" >>>> parser = OptionParser(usage=usage, epilog=epilog) >>>> parser.parse_args(['', '--help']) > Usage: [options] arg1 arg2 > > Options: > -h, --help show this help message and exit > > that's all folks!
Very cool. Thanks! I'll update argparse to share this API. STeVe -- http://mail.python.org/mailman/listinfo/python-list