This is a simple tool to pull specific values out of JSON, or to pull JSON from JSON, at the command-line:
It’s useful to pull configuration values from within a Bash script.
Example data:
{"a": [9, 6, {"b": [99, 88, 77, "text", 55]}]}
Example commands:
$ cat example.json | jp a.2.b.3 "text" $ cat example.json | jp a.2 | jp b.3 "text" $ cat example.json | jp a.2 | jp -p b.3 text
Reblogged this on Sutoprise Avenue, A SutoCom Source.
LikeLike