Friday, 2 June 2017

unix - How can I pretty-print JSON in a shell script?

Is there a (Unix) shell script to format JSON in human-readable form?



Basically, I want it to transform the following:



{ "foo": "lorem", "bar": "ipsum" }


... into something like this:



{

"foo": "lorem",
"bar": "ipsum"
}

No comments:

Post a Comment

c++ - Does curly brackets matter for empty constructor?

Those brackets declare an empty, inline constructor. In that case, with them, the constructor does exist, it merely does nothing more than t...