Q:

Use closetag.vim script in .html.eb files

In https://stackoverflow.com/a/130741/168646 I learned about closetag.vim, which is exactly what I was hoping to find.   However, I can't seem to get it working for the .html.erb files in my rails project. 
I tried adding erb and html.erb to the list of file types that source the script (in my .vimrc file):
autocmd Filetype html,xml,erb,html.erb source ~/.vim/scripts/closetag.vim
What am I missing? 

A:

The file type of .erb files is eruby.   Add it to your autocmd:
autocmd Filetype html,xml,eruby source ~/.vim/scripts/closetag.vim

To determine what filetype Vim is using for a file, you can do:
set filetype? 
" Shows:
" filetype=eruby

