I have a whole lot of XML files, badly indented.
I wish to write a script or use a tool which re-indents all the files.
Is there such a tool, or a nice library in a mainstream scripting language (preferred are Ruby and Python), or in Java ?
I have a whole lot of XML files, badly indented.
I wish to write a script or use a tool which re-indents all the files.
Is there such a tool, or a nice library in a mainstream scripting language (preferred are Ruby and Python), or in Java ?
Here's a large list of options to do it:
http://www.dpawson.co.uk/xsl/sect2/pretty.html#d8578e19
The main ones that I'd use are the xslt stylesheet, or HTML Tidy.