3 ms·
jq makes handling json in existing bash scripts simple. It can even do some simple data wrangling via built-in functions like map. It's not a universally stan
by mywittyname 6y ago
jq makes handling json in existing bash scripts simple. It can even do some simple data wrangling via built-in functions like map. It's not a universally standard command yet, but it's available for most modern systems.
I'm not sure about similar xml cli tools, but they probably exist.
Point is, both of these should be cli tools, not shell built-ins.
- mdaniel 6y ago> I'm not sure about similar xml cli tools, but they probably exist. I :heart: xmlstarlet (sometimes installed as that name, sometimes as just "xml"): https://formulae.brew.sh/formula/xmlstarlet#default https://formulae.brew.sh/formula/xmlstarlet#default => https://xmlstar.sourceforge.io/ https://xmlstar.sourceforge.io/ The xsltproc that ships with libxslt1 is also pretty handy, although more verbose While not quite xml, pup is super handy for doing quick html selections: https://formulae.brew.sh/formula/pup#default https://formulae.brew.sh/formula/pup#default => https://github.com/EricChiang/pup#readme https://github.com/EricChiang/pup#readme
- Iwan-Zotow 6y ago> I'm not sure about similar xml cli tools, but they probably exist. xsltproc of course