JSONPath
fx
JSONPath | fx | |
---|---|---|
1 | 50 | |
927 | 18,552 | |
1.5% | - | |
6.7 | 9.1 | |
9 days ago | 17 days ago | |
JavaScript | Go | |
GNU General Public License v3.0 or later | MIT License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
JSONPath
-
jq 1.7 Released
Another great alternative is JSONPath[1] which unfortunately not as widely supported and known despite being brilliant!
It's inspired by XPath so it's very familiar instead of a complete new DSL. The killer feature imo is the recursive key lookup so you can write `people..address` and it'll find all "address" keys that descend from "people" anywhere in the JSON. It's by far my favorite parsing language for JSON and I wrote an introduction blog on how to use it in JSON dataset parsing [2] :)
1 - https://github.com/JSONPath-Plus/JSONPath
2 - https://scrapfly.io/blog/parse-json-jsonpath-python/
fx
- Bash/Zsh autocomplete for JSON fields
- Fx 32.0, now with YAML support too
- Fx JSON viewer now supports YAML
-
Jaq – A jq clone focused on correctness, speed, and simplicity
There's also this awesome tool to make JSON interactively navigable in the terminal:
https://fx.wtf
- Fx 31.0.0 Release
- FLaNK Stack Weekly for 30 Oct 2023
- jq 1.7
-
Modern Linux Tools vs. Unix Classics: Which Would I Choose?
Using awk/sed to parse json seems to be using the wrong tool for the job.
As an alternative to jq with easier to remember syntax, see https://fx.wtf/
Recent discussion: https://news.ycombinator.com/item?id=37567009
- Fx – Terminal JSON Viewer
- fx – terminal JSON viewer
What are some alternatives?
gojq - Pure Go implementation of jq
jless - jless is a command-line JSON viewer designed for reading, exploring, and searching through JSON data.
jet - CLI to transform between JSON, EDN, YAML and Transit using Clojure
jiq - jid on jq - interactive JSON query tool using jq expressions
fq - jq for binary formats - tool, language and decoders for working with binary and text formats
jid - json incremental digger
visidata - A terminal spreadsheet multitool for discovering and arranging data
rq - Record Query - A tool for doing record analysis and transformation
yamlpath - YAML/JSON/EYAML/Compatible get/set/merge/validate/scan/convert/diff processors using powerful, intuitive, command-line friendly syntax.
kubectl-jq - Kubectl plugin that works like "kubectl get" but runs everything through a JQ program you provide
rsl - reserialise: lossy but versatile conversion between data serialisation formats
ngs - Next Generation Shell (NGS)