2019-03-04 03:28:35 -05:00
|
|
|
if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'coffee-script') != -1
|
|
|
|
finish
|
|
|
|
endif
|
|
|
|
|
Add support for basic languages
coffee, cucumbeer, eruby, haml, haskell, javascript,
json, less, nginx, ocaml, ruby, sass, scss, slim,
stylus, textile, tmux
2013-09-12 10:17:03 -04:00
|
|
|
" Language: CoffeeScript
|
2014-11-10 20:37:21 -05:00
|
|
|
" Maintainer: Mick Koch <mick@kochm.co>
|
Add support for basic languages
coffee, cucumbeer, eruby, haml, haskell, javascript,
json, less, nginx, ocaml, ruby, sass, scss, slim,
stylus, textile, tmux
2013-09-12 10:17:03 -04:00
|
|
|
" URL: http://github.com/kchmck/vim-coffee-script
|
|
|
|
" License: WTFPL
|
|
|
|
|
2016-09-11 07:24:17 -04:00
|
|
|
if exists('b:current_syntax')
|
|
|
|
let s:current_syntax_save = b:current_syntax
|
|
|
|
endif
|
|
|
|
|
Add support for basic languages
coffee, cucumbeer, eruby, haml, haskell, javascript,
json, less, nginx, ocaml, ruby, sass, scss, slim,
stylus, textile, tmux
2013-09-12 10:17:03 -04:00
|
|
|
" Syntax highlighting for text/coffeescript script tags
|
|
|
|
syn include @htmlCoffeeScript syntax/coffee.vim
|
2017-02-02 15:16:29 -05:00
|
|
|
syn region coffeeScript start=#<script [^>]*type=['"]\?text/coffeescript['"]\?[^>]*>#
|
Add support for basic languages
coffee, cucumbeer, eruby, haml, haskell, javascript,
json, less, nginx, ocaml, ruby, sass, scss, slim,
stylus, textile, tmux
2013-09-12 10:17:03 -04:00
|
|
|
\ end=#</script>#me=s-1 keepend
|
|
|
|
\ contains=@htmlCoffeeScript,htmlScriptTag,@htmlPreproc
|
|
|
|
\ containedin=htmlHead
|
2015-07-18 17:05:45 -04:00
|
|
|
|
2016-09-11 07:24:17 -04:00
|
|
|
if exists('s:current_syntax_save')
|
|
|
|
let b:current_syntax = s:current_syntax_save
|
|
|
|
unlet s:current_syntax_save
|
|
|
|
endif
|
2019-03-04 03:28:35 -05:00
|
|
|
if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'glsl') != -1
|
|
|
|
finish
|
2017-12-06 07:17:06 -05:00
|
|
|
endif
|
2019-03-04 03:28:35 -05:00
|
|
|
|
2017-12-06 07:17:06 -05:00
|
|
|
" Language: OpenGL Shading Language
|
|
|
|
" Maintainer: Sergey Tikhomirov <sergey@tikhomirov.io>
|
|
|
|
|
|
|
|
syn include @GLSL syntax/glsl.vim
|
|
|
|
syn region ShaderScript
|
|
|
|
\ start="<script [^>]*type=\('\|\"\)x-shader/x-\(vertex\|fragment\)\('\|\"\)[^>]*>"
|
|
|
|
\ keepend
|
|
|
|
\ end="</script>"me=s-1
|
|
|
|
\ contains=@GLSL,htmlScriptTag,@htmlPreproc
|
2019-03-04 03:28:35 -05:00
|
|
|
if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'html5') != -1
|
|
|
|
finish
|
2017-03-23 06:28:19 -04:00
|
|
|
endif
|
2019-03-04 03:28:35 -05:00
|
|
|
|
2017-03-23 06:28:19 -04:00
|
|
|
" Vim syntax file
|
|
|
|
" Language: HTML (version 5.1)
|
|
|
|
" Last Change: 2017 Feb 15
|
|
|
|
" License: Public domain
|
|
|
|
" (but let me know if you like :) )
|
|
|
|
"
|
|
|
|
" Maintainer: Kao, Wei-Ko(othree) ( othree AT gmail DOT com )
|
|
|
|
|
|
|
|
" Comment
|
|
|
|
" https://github.com/w3c/html/issues/694
|
|
|
|
syntax region htmlComment start=+<!--+ end=+-->+ contains=@Spell
|
|
|
|
syntax region htmlComment start=+<!DOCTYPE+ keepend end=+>+
|
2019-03-04 03:28:35 -05:00
|
|
|
if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'less') != -1
|
|
|
|
finish
|
2015-07-18 17:05:45 -04:00
|
|
|
endif
|
2019-03-04 03:28:35 -05:00
|
|
|
|
2014-08-27 12:16:33 -04:00
|
|
|
if !exists("g:less_html_style_tags")
|
|
|
|
let g:less_html_style_tags = 1
|
|
|
|
endif
|
|
|
|
|
|
|
|
if !g:less_html_style_tags
|
|
|
|
finish
|
|
|
|
endif
|
|
|
|
|
|
|
|
" Unset (but preserve) so that less will run.
|
2014-11-10 20:37:21 -05:00
|
|
|
if exists("b:current_syntax")
|
|
|
|
let s:pre_less_cur_syn = b:current_syntax
|
|
|
|
unlet b:current_syntax
|
|
|
|
endif
|
2014-08-27 12:16:33 -04:00
|
|
|
|
|
|
|
" Inspired by code from github.com/kchmck/vim-coffee-script
|
|
|
|
" and the html syntax file included with vim 7.4.
|
|
|
|
|
|
|
|
syn include @htmlLess syntax/less.vim
|
|
|
|
|
|
|
|
" We have to explicitly add to htmlHead (containedin) as that region specifies 'contains'.
|
|
|
|
syn region lessStyle start=+<style [^>]*type *=[^>]*text/less[^>]*>+ keepend end=+</style>+ contains=@htmlLess,htmlTag,htmlEndTag,htmlCssStyleComment,@htmlPreproc containedin=htmlHead
|
|
|
|
|
|
|
|
" Reset since 'less' isn't really the current_syntax.
|
2014-11-10 20:37:21 -05:00
|
|
|
if exists("s:pre_less_cur_syn")
|
|
|
|
let b:current_syntax = s:pre_less_cur_syn
|
|
|
|
endif
|