mirror of
https://github.com/vim/vim.git
synced 2025-07-26 11:04:33 -04:00
Runtime file updates. (Tim Pope)
This commit is contained in:
parent
4eccc3e301
commit
6af737fdb4
29
runtime/compiler/cucumber.vim
Normal file
29
runtime/compiler/cucumber.vim
Normal file
@ -0,0 +1,29 @@
|
|||||||
|
" Vim compiler file
|
||||||
|
" Compiler: Cucumber
|
||||||
|
" Maintainer: Tim Pope <vimNOSPAM@tpope.org>
|
||||||
|
" Last Change: 2010 Aug 09
|
||||||
|
|
||||||
|
if exists("current_compiler")
|
||||||
|
finish
|
||||||
|
endif
|
||||||
|
let current_compiler = "cucumber"
|
||||||
|
|
||||||
|
if exists(":CompilerSet") != 2 " older Vim always used :setlocal
|
||||||
|
command -nargs=* CompilerSet setlocal <args>
|
||||||
|
endif
|
||||||
|
|
||||||
|
let s:cpo_save = &cpo
|
||||||
|
set cpo-=C
|
||||||
|
|
||||||
|
CompilerSet makeprg=cucumber
|
||||||
|
|
||||||
|
CompilerSet errorformat=
|
||||||
|
\%W%m\ (Cucumber::Undefined),
|
||||||
|
\%E%m\ (%.%#),
|
||||||
|
\%Z%f:%l,
|
||||||
|
\%Z%f:%l:%.%#
|
||||||
|
|
||||||
|
let &cpo = s:cpo_save
|
||||||
|
unlet s:cpo_save
|
||||||
|
|
||||||
|
" vim:set sw=2 sts=2:
|
@ -1,7 +1,7 @@
|
|||||||
" Vim filetype plugin
|
" Vim filetype plugin
|
||||||
" Language: Cucumber
|
" Language: Cucumber
|
||||||
" Maintainer: Tim Pope <vimNOSPAM@tpope.org>
|
" Maintainer: Tim Pope <vimNOSPAM@tpope.org>
|
||||||
" Last Change: 2010 May 21
|
" Last Change: 2010 Aug 09
|
||||||
|
|
||||||
" Only do this when not done yet for this buffer
|
" Only do this when not done yet for this buffer
|
||||||
if (exists("b:did_ftplugin"))
|
if (exists("b:did_ftplugin"))
|
||||||
@ -80,7 +80,7 @@ function! s:stepmatch(receiver,target)
|
|||||||
endif
|
endif
|
||||||
catch
|
catch
|
||||||
endtry
|
endtry
|
||||||
if has("ruby")
|
if has("ruby") && pattern !~ '\\\@<!#{'
|
||||||
ruby VIM.command("return #{if (begin; Kernel.eval('/'+VIM.evaluate('pattern')+'/'); rescue SyntaxError; end) === VIM.evaluate('a:target') then 1 else 0 end}")
|
ruby VIM.command("return #{if (begin; Kernel.eval('/'+VIM.evaluate('pattern')+'/'); rescue SyntaxError; end) === VIM.evaluate('a:target') then 1 else 0 end}")
|
||||||
else
|
else
|
||||||
return 0
|
return 0
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
" Language: Haml
|
" Language: Haml
|
||||||
" Maintainer: Tim Pope <vimNOSPAM@tpope.org>
|
" Maintainer: Tim Pope <vimNOSPAM@tpope.org>
|
||||||
" Filenames: *.haml
|
" Filenames: *.haml
|
||||||
" Last Change: 2010 Jul 26
|
" Last Change: 2010 Aug 09
|
||||||
|
|
||||||
if exists("b:current_syntax")
|
if exists("b:current_syntax")
|
||||||
finish
|
finish
|
||||||
@ -21,7 +21,7 @@ syn include @hamlRubyTop syntax/ruby.vim
|
|||||||
|
|
||||||
syn case match
|
syn case match
|
||||||
|
|
||||||
syn region rubyCurlyBlock start="{" end="}" contains=@hamlRubyTop contained containedin=rubyInterpolation
|
syn region rubyCurlyBlock start="{" end="}" contains=@hamlRubyTop contained
|
||||||
syn cluster hamlRubyTop add=rubyCurlyBlock
|
syn cluster hamlRubyTop add=rubyCurlyBlock
|
||||||
|
|
||||||
syn cluster hamlComponent contains=hamlAttributes,hamlAttributesHash,hamlClassChar,hamlIdChar,hamlObject,hamlDespacer,hamlSelfCloser,hamlRuby,hamlPlainChar,hamlInterpolatable
|
syn cluster hamlComponent contains=hamlAttributes,hamlAttributesHash,hamlClassChar,hamlIdChar,hamlObject,hamlDespacer,hamlSelfCloser,hamlRuby,hamlPlainChar,hamlInterpolatable
|
||||||
@ -47,7 +47,7 @@ syn region hamlRuby matchgroup=hamlRubyChar start="-" skip=",
|
|||||||
syn match hamlPlainChar "\\" contained
|
syn match hamlPlainChar "\\" contained
|
||||||
syn region hamlInterpolatable matchgroup=hamlInterpolatableChar start="!\===\|!=\@!" end="$" keepend contained contains=hamlInterpolation,hamlInterpolationEscape,@hamlHtmlTop
|
syn region hamlInterpolatable matchgroup=hamlInterpolatableChar start="!\===\|!=\@!" end="$" keepend contained contains=hamlInterpolation,hamlInterpolationEscape,@hamlHtmlTop
|
||||||
syn region hamlInterpolatable matchgroup=hamlInterpolatableChar start="&==\|&=\@!" end="$" keepend contained contains=hamlInterpolation,hamlInterpolationEscape
|
syn region hamlInterpolatable matchgroup=hamlInterpolatableChar start="&==\|&=\@!" end="$" keepend contained contains=hamlInterpolation,hamlInterpolationEscape
|
||||||
syn region hamlInterpolation matchgroup=hamlInterpolationDelimiter start="#{" end="}" contains=@hamlRubyTop
|
syn region hamlInterpolation matchgroup=hamlInterpolationDelimiter start="#{" end="}" contains=@hamlRubyTop containedin=javascriptStringS,javascriptStringD
|
||||||
syn match hamlInterpolationEscape "\\\@<!\%(\\\\\)*\\\%(\\\ze#{\|#\ze{\)"
|
syn match hamlInterpolationEscape "\\\@<!\%(\\\\\)*\\\%(\\\ze#{\|#\ze{\)"
|
||||||
syn region hamlErbInterpolation matchgroup=hamlInterpolationDelimiter start="<%[=-]\=" end="-\=%>" contained contains=@hamlRubyTop
|
syn region hamlErbInterpolation matchgroup=hamlInterpolationDelimiter start="<%[=-]\=" end="-\=%>" contained contains=@hamlRubyTop
|
||||||
|
|
||||||
@ -55,16 +55,16 @@ syn region hamlAttributeString start=+\%(=\s*\)\@<='+ skip=+\%(\\\\\)*\\'+ end=
|
|||||||
syn region hamlAttributeString start=+\%(=\s*\)\@<="+ skip=+\%(\\\\\)*\\"+ end=+"+ contains=hamlInterpolation,hamlInterpolationEscape
|
syn region hamlAttributeString start=+\%(=\s*\)\@<="+ skip=+\%(\\\\\)*\\"+ end=+"+ contains=hamlInterpolation,hamlInterpolationEscape
|
||||||
syn match hamlAttributeVariable "\%(=\s*\)\@<=\%(@@\=\|\$\)\=\w\+" contained
|
syn match hamlAttributeVariable "\%(=\s*\)\@<=\%(@@\=\|\$\)\=\w\+" contained
|
||||||
|
|
||||||
syn match hamlHelper "\<action_view?\|\<block_is_haml?\|\<is_haml?\|\.\@<!\<flatten" contained containedin=@hamlEmbeddedRuby,@hamlRubyTop,rubyInterpolation
|
syn match hamlHelper "\<action_view?\|\<block_is_haml?\|\<is_haml?\|\.\@<!\<flatten" contained containedin=@hamlEmbeddedRuby,@hamlRubyTop
|
||||||
syn keyword hamlHelper capture_haml escape_once find_and_preserve haml_concat haml_indent haml_tag html_attrs html_esape init_haml_helpers list_of non_haml precede preserve succeed surround tab_down tab_up page_class contained containedin=@hamlEmbeddedRuby,@hamlRubyTop,rubyInterpolation
|
syn keyword hamlHelper capture_haml escape_once find_and_preserve haml_concat haml_indent haml_tag html_attrs html_esape init_haml_helpers list_of non_haml precede preserve succeed surround tab_down tab_up page_class contained containedin=@hamlEmbeddedRuby,@hamlRubyTop
|
||||||
|
|
||||||
syn cluster hamlHtmlTop contains=@htmlTop,htmlBold,htmlItalic,htmlUnderline
|
syn cluster hamlHtmlTop contains=@htmlTop,htmlBold,htmlItalic,htmlUnderline
|
||||||
syn region hamlPlainFilter matchgroup=hamlFilter start="^\z(\s*\):\%(plain\|preserve\|redcloth\|textile\|markdown\|maruku\)\s*$" end="^\%(\z1 \| *$\)\@!" contains=@hamlHtmlTop,rubyInterpolation
|
syn region hamlPlainFilter matchgroup=hamlFilter start="^\z(\s*\):\%(plain\|preserve\|redcloth\|textile\|markdown\|maruku\)\s*$" end="^\%(\z1 \| *$\)\@!" contains=@hamlHtmlTop,hamlInterpolation
|
||||||
syn region hamlEscapedFilter matchgroup=hamlFilter start="^\z(\s*\):\%(escaped\|cdata\)\s*$" end="^\%(\z1 \| *$\)\@!" contains=rubyInterpolation
|
syn region hamlEscapedFilter matchgroup=hamlFilter start="^\z(\s*\):\%(escaped\|cdata\)\s*$" end="^\%(\z1 \| *$\)\@!" contains=hamlInterpolation
|
||||||
syn region hamlErbFilter matchgroup=hamlFilter start="^\z(\s*\):erb\s*$" end="^\%(\z1 \| *$\)\@!" contains=@hamlHtmlTop,hamlErbInterpolation
|
syn region hamlErbFilter matchgroup=hamlFilter start="^\z(\s*\):erb\s*$" end="^\%(\z1 \| *$\)\@!" contains=@hamlHtmlTop,hamlErbInterpolation
|
||||||
syn region hamlRubyFilter matchgroup=hamlFilter start="^\z(\s*\):ruby\s*$" end="^\%(\z1 \| *$\)\@!" contains=@hamlRubyTop
|
syn region hamlRubyFilter matchgroup=hamlFilter start="^\z(\s*\):ruby\s*$" end="^\%(\z1 \| *$\)\@!" contains=@hamlRubyTop
|
||||||
syn region hamlJavascriptFilter matchgroup=hamlFilter start="^\z(\s*\):javascript\s*$" end="^\%(\z1 \| *$\)\@!" contains=@htmlJavaScript,rubyInterpolation keepend
|
syn region hamlJavascriptFilter matchgroup=hamlFilter start="^\z(\s*\):javascript\s*$" end="^\%(\z1 \| *$\)\@!" contains=@htmlJavaScript,hamlInterpolation keepend
|
||||||
syn region hamlCSSFilter matchgroup=hamlFilter start="^\z(\s*\):css\s*$" end="^\%(\z1 \| *$\)\@!" contains=@htmlCss,rubyInterpolation keepend
|
syn region hamlCSSFilter matchgroup=hamlFilter start="^\z(\s*\):css\s*$" end="^\%(\z1 \| *$\)\@!" contains=@htmlCss,hamlInterpolation keepend
|
||||||
syn region hamlSassFilter matchgroup=hamlFilter start="^\z(\s*\):sass\s*$" end="^\%(\z1 \| *$\)\@!" contains=@hamlSassTop
|
syn region hamlSassFilter matchgroup=hamlFilter start="^\z(\s*\):sass\s*$" end="^\%(\z1 \| *$\)\@!" contains=@hamlSassTop
|
||||||
|
|
||||||
syn region hamlJavascriptBlock start="^\z(\s*\)%script" nextgroup=@hamlComponent,hamlError end="^\%(\z1 \| *$\)\@!" contains=@hamlTop,@htmlJavaScript keepend
|
syn region hamlJavascriptBlock start="^\z(\s*\)%script" nextgroup=@hamlComponent,hamlError end="^\%(\z1 \| *$\)\@!" contains=@hamlTop,@htmlJavaScript keepend
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
" Language: Sass
|
" Language: Sass
|
||||||
" Maintainer: Tim Pope <vimNOSPAM@tpope.org>
|
" Maintainer: Tim Pope <vimNOSPAM@tpope.org>
|
||||||
" Filenames: *.sass
|
" Filenames: *.sass
|
||||||
" Last Change: 2010 Jul 28
|
" Last Change: 2010 Aug 9
|
||||||
|
|
||||||
if exists("b:current_syntax")
|
if exists("b:current_syntax")
|
||||||
finish
|
finish
|
||||||
@ -20,7 +20,7 @@ syn region sassDefinition matchgroup=cssBraces start="{" end="}" contains=TOP
|
|||||||
syn match sassProperty "\%([{};]\s*\|^\)\@<=\%([[:alnum:]-]\|#{[^{}]*}\)\+:" contains=css.*Prop skipwhite nextgroup=sassCssAttribute contained containedin=sassDefinition
|
syn match sassProperty "\%([{};]\s*\|^\)\@<=\%([[:alnum:]-]\|#{[^{}]*}\)\+:" contains=css.*Prop skipwhite nextgroup=sassCssAttribute contained containedin=sassDefinition
|
||||||
syn match sassProperty "^\s*\zs\s\%(\%([[:alnum:]-]\|#{[^{}]*}\)\+:\|:[[:alnum:]-]\+\)"hs=s+1 contains=css.*Prop skipwhite nextgroup=sassCssAttribute
|
syn match sassProperty "^\s*\zs\s\%(\%([[:alnum:]-]\|#{[^{}]*}\)\+:\|:[[:alnum:]-]\+\)"hs=s+1 contains=css.*Prop skipwhite nextgroup=sassCssAttribute
|
||||||
syn match sassProperty "^\s*\zs\s\%(:\=[[:alnum:]-]\+\s*=\)"hs=s+1 contains=css.*Prop skipwhite nextgroup=sassCssAttribute
|
syn match sassProperty "^\s*\zs\s\%(:\=[[:alnum:]-]\+\s*=\)"hs=s+1 contains=css.*Prop skipwhite nextgroup=sassCssAttribute
|
||||||
syn match sassCssAttribute +\%("\%([^"]\|\\"\)*"\|'\%([^']\|\\'\)*'\|[^{};]\)*+ contained contains=@sassCssAttributes,sassVariable,sassFunction
|
syn match sassCssAttribute +\%("\%([^"]\|\\"\)*"\|'\%([^']\|\\'\)*'\|#{[^{}]*}\|[^{};]\)*+ contained contains=@sassCssAttributes,sassVariable,sassFunction,sassInterpolation
|
||||||
syn match sassDefault "!default\>" contained
|
syn match sassDefault "!default\>" contained
|
||||||
syn match sassVariable "!\%(important\>\|default\>\)\@![[:alnum:]_-]\+"
|
syn match sassVariable "!\%(important\>\|default\>\)\@![[:alnum:]_-]\+"
|
||||||
syn match sassVariable "$[[:alnum:]_-]\+"
|
syn match sassVariable "$[[:alnum:]_-]\+"
|
||||||
@ -34,15 +34,14 @@ syn match sassFunction "\<\%(unquote\|quote\)\>(\@=" contained
|
|||||||
syn match sassFunction "\<\%(percentage\|round\|ceil\|floor\|abs\)\>(\@=" contained
|
syn match sassFunction "\<\%(percentage\|round\|ceil\|floor\|abs\)\>(\@=" contained
|
||||||
syn match sassFunction "\<\%(type-of\|unit\|unitless\|comparable\)\>(\@=" contained
|
syn match sassFunction "\<\%(type-of\|unit\|unitless\|comparable\)\>(\@=" contained
|
||||||
|
|
||||||
syn region sassInterpolation matchgroup=sassInterpolationDelimiter start="#{" end="}" contains=@sassCssAttributes,sassVariable,sassFunction containedin=cssStringQ,cssStringQQ,sassCssAttribute,sassProperty
|
syn region sassInterpolation matchgroup=sassInterpolationDelimiter start="#{" end="}" contains=@sassCssAttributes,sassVariable,sassFunction containedin=cssStringQ,cssStringQQ,sassProperty
|
||||||
|
|
||||||
syn match sassMixinName "[[:alnum:]_-]\+" contained nextgroup=sassCssAttribute
|
syn match sassMixinName "[[:alnum:]_-]\+" contained nextgroup=sassCssAttribute
|
||||||
syn match sassMixin "^=" nextgroup=sassMixinName
|
syn match sassMixin "^=" nextgroup=sassMixinName
|
||||||
syn match sassMixin "^\s*\zs@mixin" nextgroup=sassMixinName skipwhite
|
syn match sassMixin "\%([{};]\s*\|^\s*\)\@<=@mixin" nextgroup=sassMixinName skipwhite
|
||||||
syn match sassMixing "^\s\+\zs+" nextgroup=sassMixinName
|
syn match sassMixing "^\s\+\zs+" nextgroup=sassMixinName
|
||||||
syn match sassMixing "^\s\+\zs@include" nextgroup=sassMixinName skipwhite
|
syn match sassMixing "\%([{};]\s*\|^\s*\)\@<=@include" nextgroup=sassMixinName skipwhite
|
||||||
syn match sassMixing "\%([{};]\s*\|^\)\@<=@include" nextgroup=sassMixinName skipwhite contained containedin=sassDefinition
|
syn match sassExtend "\%([{};]\s*\|^\s*\)\@<=@extend"
|
||||||
syn match sassExtend "^\s\+\zs@extend"
|
|
||||||
|
|
||||||
syn match sassEscape "^\s*\zs\\"
|
syn match sassEscape "^\s*\zs\\"
|
||||||
syn match sassIdChar "#[[:alnum:]_-]\@=" nextgroup=sassId
|
syn match sassIdChar "#[[:alnum:]_-]\@=" nextgroup=sassId
|
||||||
|
Loading…
x
Reference in New Issue
Block a user