summaryrefslogtreecommitdiffstats
path: root/autoload/polyglot
diff options
context:
space:
mode:
Diffstat (limited to 'autoload/polyglot')
-rw-r--r--autoload/polyglot/ft.vim11
-rw-r--r--autoload/polyglot/sleuth.vim2
2 files changed, 12 insertions, 1 deletions
diff --git a/autoload/polyglot/ft.vim b/autoload/polyglot/ft.vim
index f872bf9c..2e4c1f69 100644
--- a/autoload/polyglot/ft.vim
+++ b/autoload/polyglot/ft.vim
@@ -172,6 +172,17 @@ func polyglot#ft#FTent()
setf dtd
endfunc
+func polyglot#ft#ExCheck()
+ let lines = getline(1, min([line("$"), 100]))
+ if exists('g:filetype_euphoria')
+ exe 'setf ' . g:filetype_euphoria
+ elseif match(lines, '^--\|^ifdef\>\|^include\>') > -1
+ setf euphoria3
+ else
+ setf elixir
+ endif
+endfunc
+
func polyglot#ft#EuphoriaCheck()
if exists('g:filetype_euphoria')
exe 'setf ' . g:filetype_euphoria
diff --git a/autoload/polyglot/sleuth.vim b/autoload/polyglot/sleuth.vim
index 0785dfbf..d308561c 100644
--- a/autoload/polyglot/sleuth.vim
+++ b/autoload/polyglot/sleuth.vim
@@ -257,7 +257,7 @@ let s:globs = {
\ 'jam': '*.jpl,*.jpr,Prl*.*,JAM*.*',
\ 'java': '*.java,*.jav',
\ 'javacc': '*.jj,*.jjt',
- \ 'javascript': '*.js,*._js,*.bones,*.cjs,*.es,*.es6,*.frag,*.gs,*.jake,*.jsb,*.jscad,*.jsfl,*.jsm,*.jss,*.jsx,*.mjs,*.njs,*.pac,*.sjs,*.ssjs,*.xsjs,*.xsjslib,*.javascript,Jakefile',
+ \ 'javascript': '*.js,*._js,*.bones,*.cjs,*.es,*.es6,*.frag,*.gs,*.jake,*.javascript,*.jsb,*.jscad,*.jsfl,*.jsm,*.jss,*.jsx,*.mjs,*.njs,*.pac,*.sjs,*.ssjs,*.xsjs,*.xsjslib,Jakefile',
\ 'javascriptreact': '*.jsx',
\ 'jess': '*.clp',
\ 'jgraph': '*.jgr',