3 ms·
jq is the AWK of today. I'm in favour of jq in *nix base. I use it almost as much as grep | cut | sort. JSON is ubiquitous now. So much so that even my <con
by inopinatus 7y ago
jq is the AWK of today. I'm in favour of jq in *nix base. I use it almost as much as grep | cut | sort.
JSON is ubiquitous now. So much so that even my <conservative enterprise customers>, who 20 years preferred data in CSV, 10 years ago preferred XML, now want to exchange data in JSON.
- dmurray 7y agoCSV still seems to be the standard in finance.
- solatic 7y agoPrecisely, because JSON is ubiquitous (unlike XML) and relatively safe to parse (unlike CSV). It's not perfect - it doesn't have higher-order features like types/schemas or functions built in. But JSON + jq is a workhorse. I agree that distros do people a disservice by not bundling jq in base (and attempting to provide JSON output for distro-specific tooling).
- lenkite 7y agoSomething better than jq please. It has the most arcane and inconsistent syntax that I have ever seen in a CLI tool. There are newer tools like jp with simpler language that can be understood by mere mortals with limited brain power.
- kmelve 7y agoYou should check out GROQ (https://groq.dev https://groq.dev), it's a query language for JSON.