]> granicus.if.org Git - python/commitdiff
Issue #13685 - Update argparse help message for % sign usage.
authorSenthil Kumaran <senthil@uthcode.com>
Tue, 26 Jun 2012 06:17:19 +0000 (14:17 +0800)
committerSenthil Kumaran <senthil@uthcode.com>
Tue, 26 Jun 2012 06:17:19 +0000 (14:17 +0800)
Doc/library/argparse.rst

index 186e12da312a82e95cd5b3e29b99f1739e7ce830..d64f8a28759c3d4a7d2d9e3bcde2e2a4ea327898 100644 (file)
@@ -1082,6 +1082,9 @@ specifiers include the program name, ``%(prog)s`` and most keyword arguments to
    optional arguments:
     -h, --help  show this help message and exit
 
+As the help string supports %-formatting, if you want a literal ``%`` to appear
+in the help string, you must escape it as ``%%``.
+
 :mod:`argparse` supports silencing the help entry for certain options, by
 setting the ``help`` value to ``argparse.SUPPRESS``::