In Vim, what is the command to correct the indentation of all the lines?
Often times I\'ll copy and paste code into a remote terminal and have the whole thing messed
You can use tidy application/utility to indent HTML & XML files and it works pretty well in indenting those files.
Prettify an XML file
:!tidy -mi -xml %
Prettify an HTML file
:!tidy -mi -html %