Now usually, vim's super-powers allow "gg=G" - which automagically indents code, according to the filetype syntax.
Here's what you need to do in order to use that for XML:
Code: Select all
:filetype plugin indent on
:set nocompatible
:set filetype=xml