summaryrefslogtreecommitdiffstats
path: root/ftdetect/polyglot.vim
diff options
context:
space:
mode:
Diffstat (limited to 'ftdetect/polyglot.vim')
-rw-r--r--ftdetect/polyglot.vim12
1 files changed, 12 insertions, 0 deletions
diff --git a/ftdetect/polyglot.vim b/ftdetect/polyglot.vim
index 3024bb83..3e74c6ff 100644
--- a/ftdetect/polyglot.vim
+++ b/ftdetect/polyglot.vim
@@ -72,6 +72,18 @@ au BufNewFile,BufRead *.ejs set filetype=jst
au BufNewFile,BufRead *.jst set filetype=jst
au BufNewFile,BufRead *.hamljs set filetype=jst
autocmd BufNewFile,BufRead *.less setf less
+au BufNewFile,BufRead *.liquid set ft=liquid
+au BufNewFile,BufRead */_layouts/*.html,*/_includes/*.html set ft=liquid
+au BufNewFile,BufRead *.html,*.xml,*.textile
+ \ if getline(1) == '---' | set ft=liquid | endif
+au BufNewFile,BufRead *.markdown,*.mkd,*.mkdn,*.md
+ \ if getline(1) == '---' |
+ \ let b:liquid_subtype = 'markdown' |
+ \ set ft=liquid |
+ \ endif
+au BufNewFile,BufRead */templates/**.liquid,*/layout/**.liquid,*/snippets/**.liquid
+ \ let b:liquid_subtype = 'html' |
+ \ set ft=liquid |
autocmd BufNewFile,BufRead *.markdown,*.md,*.mdown,*.mkd,*.mkdn
\ if &ft =~# '^\%(conf\|modula2\)$' |
\ set ft=markdown |