xml2js command line interface version
Simple XML to JavaScript object converter. Uses node-xml2js.
Usage:
xml2js [-h]
options:
-h print this help
echo '<a><nested>Hello</nested><b>world</b></a>' | xml2js
{
"a": {
"nested": "Hello",
"b": "world"
}
}
$ echo '
<a>hello</a>
<a>hello2 </a>
' | ../xml2js-cli/bin/xml2js-stream '{"normalize":true}' | jsontool -g
[
{
"a": "hello"
},
{
"a": "hello2"
}
]