Tom Browder <tom.brow...@gmail.com> added the comment: On Sun, Aug 22, 2010 at 17:06, Steven Bethard <rep...@bugs.python.org> wrote: ... > import argparse > import sys > > parser = argparse.ArgumentParser() > parser.add_argument('--foo') > > if len(sys.argv) == 1: > parser.print_help() > else: > print(parser.parse_args())
Of course that works, but I want to be able to customize the parser so it shows something like: Usage: <program name> [options] Use option '-h' for help. Two problems for me with current behavior: 1. "usage" and "optional" => not capitalized 2. usage: temp.py [-h] [--foo FOO] => gets very lengthy and mind numbing for programs with lots of options Regards, -Tom ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue9653> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com