shithub: xmltools

ref: f896677cdcd52890b3bc215d655c7bea323a4755
dir: /README/

View raw version
XML tools

This package requires libxml from 9atom


XQ: xml query

cat file.xml | xq '/path'
xq -f file.xml '/path'

path is an XPath (but not everything is supported).

Supported XPath features:

- @attr: /hello/world/@attr
- text(): /hello/world/text()
- [@attr='value']: /hello/world[@attr='second']/stuff
- [2]: /hello/world[2]/stuff