Tip #551: automatic indenting XML file in VIM with the help of XSLT
Is anyone using the tip #551 ? vim on debian is shipped with the
proper syntax file, now I am trying to get indentation for xml/xsl
file to work. Unfortunately I must be missing something.
I created the file indent.xsl in $HOME/.vim/indent/ I then added in .vimrc:
if version >= 540
autocmd FileType xml '[,']!xsltproc indent.xsl %
" other autocmds
" if version>540
I commented out the ">540 if". I seems to be working correctly for vim
(after pressing enter once), but it does not work with gvim.
Any advice ?
Ps: Could someone remove the ";" from the xsl file