diff options
author | Adam Stankiewicz <sheerun@sher.pl> | 2015-05-11 15:05:13 +0200 |
---|---|---|
committer | Adam Stankiewicz <sheerun@sher.pl> | 2015-05-11 15:05:13 +0200 |
commit | 271b63d71707720ad0d35590b8cb50f8f8f43014 (patch) | |
tree | 1b71daa457afc68465f66ee2afc9a00c1380f23d /ftdetect | |
parent | acd7ce59503b22ac7663fc25776efe25e266f1d4 (diff) | |
download | vim-polyglot-1.13.2.tar.gz vim-polyglot-1.13.2.zip |
Updatev1.13.2
Diffstat (limited to 'ftdetect')
-rw-r--r-- | ftdetect/polyglot.vim | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/ftdetect/polyglot.vim b/ftdetect/polyglot.vim index 3cec93cf..8edb9a9d 100644 --- a/ftdetect/polyglot.vim +++ b/ftdetect/polyglot.vim @@ -48,18 +48,19 @@ autocmd BufNewFile,BufRead * let s:current_fileformats = '' let s:current_fileencodings = '' function! s:gofiletype_pre() - let s:current_fileformats = &g:fileformats - let s:current_fileencodings = &g:fileencodings - set fileencodings=utf-8 fileformats=unix - setlocal filetype=go + let s:current_fileformats = &g:fileformats + let s:current_fileencodings = &g:fileencodings + set fileencodings=utf-8 fileformats=unix + setlocal filetype=go endfunction function! s:gofiletype_post() - let &g:fileformats = s:current_fileformats - let &g:fileencodings = s:current_fileencodings + let &g:fileformats = s:current_fileformats + let &g:fileencodings = s:current_fileencodings endfunction au BufNewFile *.go setlocal filetype=go fileencoding=utf-8 fileformat=unix au BufRead *.go call s:gofiletype_pre() au BufReadPost *.go call s:gofiletype_post() +au BufRead,BufNewFile *.tmpl set filetype=gohtmltmpl autocmd BufNewFile,BufRead *.haml,*.hamlbars,*.hamlc setf haml autocmd BufNewFile,BufRead *.sass setf sass autocmd BufNewFile,BufRead *.scss setf scss @@ -77,8 +78,9 @@ endfun au BufNewFile,BufRead * call s:SelectJavascript() autocmd BufNewFile,BufRead *.json set filetype=json autocmd BufNewFile,BufRead *.jsonp set filetype=json -au BufNewFile,BufRead *.ejs set filetype=jst -au BufNewFile,BufRead *.jst set filetype=jst +au BufNewFile,BufRead *.ejs set filetype=jst +au BufNewFile,BufRead *.jst set filetype=jst +au BufNewFile,BufRead *.djs set filetype=jst au BufNewFile,BufRead *.hamljs set filetype=jst au BufNewFile,BufRead *.ect set filetype=jst autocmd BufNewFile,BufRead *.less setf less |