summaryrefslogtreecommitdiff
path: root/runtime/filetype.vim
diff options
context:
space:
mode:
Diffstat (limited to 'runtime/filetype.vim')
-rw-r--r--runtime/filetype.vim8
1 files changed, 5 insertions, 3 deletions
diff --git a/runtime/filetype.vim b/runtime/filetype.vim
index 39030aa2c..df37ff7f5 100644
--- a/runtime/filetype.vim
+++ b/runtime/filetype.vim
@@ -1,7 +1,7 @@
" Vim support file to detect file types
"
" Maintainer: Bram Moolenaar <Bram@vim.org>
-" Last Change: 2017 Jul 11
+" Last Change: 2017 Aug 09
" Listen very carefully, I will say this only once
if exists("did_load_filetypes")
@@ -1027,7 +1027,7 @@ au BufNewFile,BufRead *.java,*.jav setf java
au BufNewFile,BufRead *.jj,*.jjt setf javacc
" JavaScript, ECMAScript
-au BufNewFile,BufRead *.js,*.javascript,*.es,*.jsx setf javascript
+au BufNewFile,BufRead *.js,*.javascript,*.es,*.jsx,*.mjs setf javascript
" Java Server Pages
au BufNewFile,BufRead *.jsp setf jsp
@@ -2267,6 +2267,8 @@ func! s:FTtex()
elseif format == 'plaintex'
let format = 'plain'
endif
+ elseif expand('%') =~ 'tex/context/.*/.*.tex'
+ let format = 'context'
else
" Default value, may be changed later:
let format = exists("g:tex_flavor") ? g:tex_flavor : 'plain'
@@ -2308,7 +2310,7 @@ func! s:FTtex()
endfunc
" ConTeXt
-au BufNewFile,BufRead tex/context/*/*.tex,*.mkii,*.mkiv,*.mkvi setf context
+au BufNewFile,BufRead *.mkii,*.mkiv,*.mkvi setf context
" Texinfo
au BufNewFile,BufRead *.texinfo,*.texi,*.txi setf texinfo