soljsonfmt - format JSON data
/usr/bin/soljsonfmt [-c|-d] [json-file...]
soljsonfmt without the –c or –d options formats JSON data in a consistent manner, including the lexical sorting of associative array indexes.
If no arguments are given, soljsonfmt reads stdin until EOF, and then writes the formatted JSON to stdout. Any JSON files specified on the command line are formatted in place.
soljsonfmt with the –c option checks whether the specified files are formatted in soljsonfmt style. The – d option displays the differences if the file is not properly formatted.
The following options are supported:
Display a usage message.
Check whether the file is formatted in the soljsonfmt style.
Display file differences from the formatted version in unified form.
The following exit values are returned:
The –c or –d options were specified, and one or more files are not in soljsonfmt normal form, or an error occurred.
Invalid command line options were specified.
See attributes(7) for descriptions of the following attributes: