I often open XML documents within gVim in Windows which end up with everything on one line. I manually do a search and replace command:
:%s/></>\r</g
to get all fields on individual lines then tab out manually the lines. This isn't going to work with sizable files, and isn't efficient in any size file anyways.
Is there a way built into gVim or is there a tool (preferably in gVim) available to help me format my XML documents into separate lines from its one line version that open up by default in gVim?
Does this do the trick?
http://vim.wikia.com/wiki/Pretty-formatting_XML
It's easily invoked as needed using:
:PrettyXML
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With