U
e5dß ã
@ sf d dl Z d dlZd dlZdd„ Zedkrbz
eƒ W n. ek
r` Z ze ej¡ W 5 dZ[X Y nX dS )é Nc C s4 d} d}t j| |d�}|jddt jdd�dtjd � |jd
dt jddd�dtjd � |jd
dddd� |jddddd� | ¡ }|j}|j }|j
}|j}|�Ž |�~ zJ|rºdd„ |D ƒ}nt
|¡f}|D ] } tj| ||dd� | d¡ qÊW n, tk
�r }
zt|
ƒ‚W 5 d }
~
X Y nX W 5 Q R X W 5 Q R X d S )Nzpython -m json.toolzZA simple command line interface for json module to validate and pretty-print JSON objects.)ÚprogÚdescriptionÚinfileú?zutf-8)Úencodingz-a JSON file to be validated or pretty-printed)ÚnargsÚtypeÚhelpÚdefaultÚoutfileÚwz%write the output of infile to outfilez--sort-keysÚ
store_trueFz5sort the output of dictionaries alphabetically by key)Úactionr
r z--json-linesz&parse input using the jsonlines formatc s s | ]}t |¡V qd S )N)ÚjsonÚloads)Ú.0Úline© r ú!/usr/lib64/python3.8/json/tool.pyÚ