JSON wrangling with jq
1 / 10

jq is a lightweight, command-line JSON processor. To use it, you construct one or more filters, and it applies those filters to a JSON document.

The simplest filter is the identity filter which returns all its input (.):

echo '{"key1": {"key2":"value1"}}' | jq '.'

This filter is handy for just pretty-printing a JSON document. I’m going to ignore the pretty-printing and jump right into using jq to transform JSON documents.

Loading...