summaryrefslogtreecommitdiffstats
path: root/Lib/json/tool.py
diff options
context:
space:
mode:
authorBob Ippolito <bob@redivi.com>2009-03-17 23:19:00 (GMT)
committerBob Ippolito <bob@redivi.com>2009-03-17 23:19:00 (GMT)
commitd914e3f8619df604ca6fa852fd210043b94f16e1 (patch)
tree99352cdd395da08a735041039f7f336a92485f8d /Lib/json/tool.py
parent277859d5910782cc31bb27f2472893b8382ad391 (diff)
downloadcpython-d914e3f8619df604ca6fa852fd210043b94f16e1.zip
cpython-d914e3f8619df604ca6fa852fd210043b94f16e1.tar.gz
cpython-d914e3f8619df604ca6fa852fd210043b94f16e1.tar.bz2
merge json library with simplejson 2.0.9 (issue 4136)
Diffstat (limited to 'Lib/json/tool.py')
-rw-r--r--Lib/json/tool.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/Lib/json/tool.py b/Lib/json/tool.py
index daedbb5..c37bb77 100644
--- a/Lib/json/tool.py
+++ b/Lib/json/tool.py
@@ -2,11 +2,11 @@ r"""Command-line tool to validate and pretty-print JSON
Usage::
- $ echo '{"json":"obj"}' | python -mjson.tool
+ $ echo '{"json":"obj"}' | python -m json.tool
{
"json": "obj"
}
- $ echo '{ 1.2:3.4}' | python -mjson.tool
+ $ echo '{ 1.2:3.4}' | python -m json.tool
Expecting property name: line 1 column 2 (char 2)
"""
@@ -24,7 +24,7 @@ def main():
infile = open(sys.argv[1], 'rb')
outfile = open(sys.argv[2], 'wb')
else:
- raise SystemExit("{0} [infile [outfile]]".format(sys.argv[0]))
+ raise SystemExit(sys.argv[0] + " [infile [outfile]]")
try:
obj = json.load(infile)
except ValueError, e: