File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -19,15 +19,12 @@ Choosing an argument parsing library
1919The standard library includes three argument parsing libraries:
2020
2121* :mod: `getopt `: a module that closely mirrors the procedural C ``getopt `` API.
22- Included in the standard library since before the initial Python 1.0 release.
2322* :mod: `!optparse `: a declarative replacement for ``getopt `` that
2423 provides equivalent functionality without requiring each application
25- to implement its own procedural option parsing logic. Included
26- in the standard library since the Python 2.3 release.
24+ to implement its own procedural option parsing logic.
2725* :mod: `argparse `: a more opinionated alternative to ``optparse `` that
2826 provides more functionality by default, at the expense of reduced application
29- flexibility in controlling exactly how arguments are processed. Included in
30- the standard library since the Python 2.7 and Python 3.2 releases.
27+ flexibility in controlling exactly how arguments are processed.
3128
3229In the absence of more specific argument parsing design constraints, :mod: `argparse `
3330is the recommended choice for implementing command line applications, as it offers
Original file line number Diff line number Diff line change 11"""A powerful, extensible, and easy-to-use option parser.
22
3- By Greg Ward <gward@python.net>
4-
5- Originally distributed as Optik.
6-
7- For support, use the optik-users@lists.sourceforge.net mailing list
8- (http://lists.sourceforge.net/lists/listinfo/optik-users).
9-
103Simple usage example:
114
125 from optparse import OptionParser
You can’t perform that action at this time.
0 commit comments