I know it's a dumb question, but I don't find the explicit answer in the docs.
Learn Vimscript the Hard Way's chapter 12 is about autocmd
s.
Here are a few examples:
:autocmd BufNewFile * :write
:autocmd BufWritePre *.html :normal gg=G
:autocmd BufNewFile,BufRead *.html setlocal nowrap
:autocmd FileType javascript nnoremap <buffer> <localleader>c I//<esc>
:autocmd FileType python nnoremap <buffer> <localleader>c I#<esc>
where the first 2 feature a :
leading their {cmd}
argument, whereas the other 3 don't.
Does autocmd
assume that its last argument is preceded by :
if I don't write it explicitly?