From: yihong Date: Fri, 22 Aug 2025 08:44:25 +0000 (+0800) Subject: gh-138019: improve help message for `json.tool` (#138037) X-Git-Tag: v3.15.0a1~618 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=531fc3a7a3998d714a9382f0bc143c05d69e9174;p=thirdparty%2FPython%2Fcpython.git gh-138019: improve help message for `json.tool` (#138037) --- diff --git a/Lib/json/tool.py b/Lib/json/tool.py index 1967817add8a..050c2fe2161e 100644 --- a/Lib/json/tool.py +++ b/Lib/json/tool.py @@ -46,7 +46,8 @@ def main(): 'to validate and pretty-print JSON objects.') parser = argparse.ArgumentParser(description=description, color=True) parser.add_argument('infile', nargs='?', - help='a JSON file to be validated or pretty-printed', + help='a JSON file to be validated or pretty-printed; ' + 'defaults to stdin', default='-') parser.add_argument('outfile', nargs='?', help='write the output of infile to outfile',