Skip to content

Instantly share code, notes, and snippets.

@benmoss
Last active June 10, 2022 15:50
Show Gist options
  • Save benmoss/78af13317f22c1ca7384c69645a8764e to your computer and use it in GitHub Desktop.
Save benmoss/78af13317f22c1ca7384c69645a8764e to your computer and use it in GitHub Desktop.
$ jq
jq - commandline JSON processor [version 1.6]
Usage: jq [options] <jq filter> [file...]
jq [options] --args <jq filter> [strings...]
jq [options] --jsonargs <jq filter> [JSON_TEXTS...]
jq is a tool for processing JSON inputs, applying the given filter to
its JSON text inputs and producing the filter's results as JSON on
standard output.
The simplest filter is ., which copies jq's input to its output
unmodified (except for formatting, but note that IEEE754 is used
for number representation internally, with all that that implies).
For more advanced filters see the jq(1) manpage ("man jq")
and/or https://stedolan.github.io/jq
Example:
$ echo '{"foo": 0}' | jq .
{
"foo": 0
}
For a listing of options, use jq --help.
<exit 2>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment