Skip to main content

Questions tagged [xmlstarlet]

Open source command line utility for XML file processing.

0 votes
1 answer
75 views

I have a Maven settings file at ~/.m2/settings.xml. I need to write some scripting that extracts the username and password from one of the server entries. I've tried using both "xmllint" ...
David M. Karr's user avatar
0 votes
1 answer
440 views

I have this command: find . -iname '*.xml' | xargs xmlstarlet sel -N z="http://abc.com/article/1.0/" \\ --var zgtag="SuperTag" -t -m "/z:profile-extension" -i "//z:...
basZero's user avatar
  • 153
3 votes
1 answer
449 views

When you follow the doc: xmlstarlet edit --help you can read that --var can be used to declare a XPath expression as a variable. Generating moc file: cat<<EOF > /tmp/file.xml <root> &...
Mévatlavé Kraspek's user avatar
3 votes
2 answers
2k views

I want to remove all the namespace attributes from the following XML. <md:EntityDescriptor xmlns="urn:_" xmlns:md="_"></md:EntityDescriptor> I have tried to remove ...
s1n7ax's user avatar
  • 437
5 votes
2 answers
606 views

I have several hundred .xhtml files in a sub-directory(*) and I want to delete all DIVs with a specific class (and the entire contents of those DIVs - including other divs, spans, image and paragraph ...
cas's user avatar
  • 84.7k
2 votes
1 answer
148 views

What is the xmlstarlet command to untag, in an XML file, a chain of tagged characters that are embedded within specified tags? Example: searching every occurrence of the tag <b>, that needs to ...
Matt5's user avatar
  • 87
-1 votes
1 answer
65 views

I want to change the version number with respect to the ip. For example for this ip 10.228.134.226, it should change the version number from 97 to 98 <qa:browsers> <browser name="...
raghav's user avatar
  • 11
0 votes
1 answer
495 views

I've tried xmlstarlet for processing an individual .xhtml files. xmlstarlet fo --omit-decl --recover --html file.xhtml This command process an individual files and prints output on terminal only. ...
minto's user avatar
  • 595

15 30 50 per page