mirror of
https://github.com/amix/vimrc
synced 2025-08-08 14:55:00 +08:00
Updated vim plugins
This commit is contained in:
@ -65,11 +65,11 @@ JSX, LESS, Lex, Limbo, LISP, LLVM intermediate language, Lua, Markdown,
|
||||
MATLAB, Mercury, NASM, Nix, Objective-C, Objective-C++, OCaml, Perl, Perl
|
||||
POD, PHP, gettext Portable Object, OS X and iOS property lists, Pug (formerly
|
||||
Jade), Puppet, Python, QML, R, Racket, RDF TriG, RDF Turtle, Relax NG,
|
||||
reStructuredText, RPM spec, Ruby, SASS/SCSS, Scala, Slim, SML, Sphinx, SQL,
|
||||
Stylus, Tcl, TeX, Texinfo, Twig, TypeScript, Vala, Verilog, VHDL, VimL, xHtml,
|
||||
XML, XSLT, XQuery, YACC, YAML, YANG data models, z80, Zope page templates, and
|
||||
Zsh. See the [manual][checkers] for details about the corresponding supported
|
||||
checkers (`:help syntastic-checkers` in Vim).
|
||||
reStructuredText, RPM spec, Ruby, SASS/SCSS, Scala, Slim, SML, Solidity,
|
||||
Sphinx, SQL, Stylus, Tcl, TeX, Texinfo, Twig, TypeScript, Vala, Verilog,
|
||||
VHDL, VimL, xHtml, XML, XSLT, XQuery, YACC, YAML, YANG data models, z80, Zope
|
||||
page templates, and Zsh. See the [manual][checkers] for details about the
|
||||
corresponding supported checkers (`:help syntastic-checkers` in Vim).
|
||||
|
||||
A number of third-party Vim plugins also provide checkers for syntastic, for
|
||||
example: [merlin][merlin], [omnisharp-vim][omnisharp], [rust.vim][rust],
|
||||
@ -456,12 +456,12 @@ For example for `jscs`:
|
||||
```vim
|
||||
function! FindConfig(prefix, what, where)
|
||||
let cfg = findfile(a:what, escape(a:where, ' ') . ';')
|
||||
return cfg !=# '' ? ' ' . a:prefix . ' ' . cfg : ''
|
||||
return cfg !=# '' ? ' ' . a:prefix . ' ' . shellescape(cfg) : ''
|
||||
endfunction
|
||||
|
||||
autocmd FileType javascript let b:syntastic_javascript_jscs_args =
|
||||
\ get(g:, 'syntastic_javascript_jscs_args', '') .
|
||||
\ FindConfig('-c', '.jscsrc', expand('<amatch>:p:h', 1))
|
||||
\ FindConfig('-c', '.jscsrc', expand('<afile>:p:h', 1))
|
||||
```
|
||||
<a name="faqbdelete"></a>
|
||||
|
||||
|
@ -89,11 +89,11 @@ function! syntastic#preprocess#dockerfile_lint(errors) abort " {{{2
|
||||
call add(out, msg)
|
||||
endfor
|
||||
catch /\m^Vim\%((\a\+)\)\=:E716/
|
||||
call syntastic#log#warn('checker dockerfile/dockerfile_lint: unrecognized error format')
|
||||
call syntastic#log#warn('checker dockerfile/dockerfile_lint: unrecognized error format (crashed checker?)')
|
||||
let out = []
|
||||
endtry
|
||||
else
|
||||
call syntastic#log#warn('checker dockerfile/dockerfile_lint: unrecognized error format')
|
||||
call syntastic#log#warn('checker dockerfile/dockerfile_lint: unrecognized error format (crashed checker?)')
|
||||
endif
|
||||
return out
|
||||
endfunction " }}}2
|
||||
@ -132,18 +132,18 @@ function! syntastic#preprocess#flow(errors) abort " {{{2
|
||||
|
||||
call add(out, msg)
|
||||
catch /\m^Vim\%((\a\+)\)\=:E716/
|
||||
call syntastic#log#warn('checker javascript/flow: unrecognized error format')
|
||||
call syntastic#log#warn('checker javascript/flow: unrecognized error format (crashed checker?)')
|
||||
let out = []
|
||||
break
|
||||
endtry
|
||||
else
|
||||
call syntastic#log#warn('checker javascript/flow: unrecognized error format')
|
||||
call syntastic#log#warn('checker javascript/flow: unrecognized error format (crashed checker?)')
|
||||
let out = []
|
||||
break
|
||||
endif
|
||||
endfor
|
||||
else
|
||||
call syntastic#log#warn('checker javascript/flow: unrecognized error format')
|
||||
call syntastic#log#warn('checker javascript/flow: unrecognized error format (crashed checker?)')
|
||||
endif
|
||||
|
||||
return out
|
||||
@ -178,11 +178,11 @@ function! syntastic#preprocess#jscs(errors) abort " {{{2
|
||||
endtry
|
||||
endfor
|
||||
else
|
||||
call syntastic#log#warn('checker javascript/jscs: unrecognized error format')
|
||||
call syntastic#log#warn('checker javascript/jscs: unrecognized error format (crashed checker?)')
|
||||
endif
|
||||
endfor
|
||||
else
|
||||
call syntastic#log#warn('checker javascript/jscs: unrecognized error format')
|
||||
call syntastic#log#warn('checker javascript/jscs: unrecognized error format (crashed checker?)')
|
||||
endif
|
||||
return out
|
||||
endfunction " }}}2
|
||||
@ -238,7 +238,7 @@ function! syntastic#preprocess#prospector(errors) abort " {{{2
|
||||
endif
|
||||
endfor
|
||||
else
|
||||
call syntastic#log#warn('checker python/prospector: unrecognized error format')
|
||||
call syntastic#log#warn('checker python/prospector: unrecognized error format (crashed checker?)')
|
||||
endif
|
||||
endif
|
||||
|
||||
@ -311,11 +311,11 @@ function! syntastic#preprocess#scss_lint(errors) abort " {{{2
|
||||
endtry
|
||||
endfor
|
||||
else
|
||||
call syntastic#log#warn('checker scss/scss_lint: unrecognized error format')
|
||||
call syntastic#log#warn('checker scss/scss_lint: unrecognized error format (crashed checker?)')
|
||||
endif
|
||||
endfor
|
||||
else
|
||||
call syntastic#log#warn('checker scss/scss_lint: unrecognized error format')
|
||||
call syntastic#log#warn('checker scss/scss_lint: unrecognized error format (crashed checker?)')
|
||||
endif
|
||||
return out
|
||||
endfunction " }}}2
|
||||
@ -351,7 +351,7 @@ function! syntastic#preprocess#stylelint(errors) abort " {{{2
|
||||
endtry
|
||||
endfor
|
||||
else
|
||||
call syntastic#log#warn('checker css/stylelint: unrecognized error format')
|
||||
call syntastic#log#warn('checker css/stylelint: unrecognized error format (crashed checker?)')
|
||||
endif
|
||||
endif
|
||||
return out
|
||||
@ -398,7 +398,7 @@ echomsg string(json)
|
||||
endtry
|
||||
endfor
|
||||
else
|
||||
call syntastic#log#warn('checker javascript/tern_lint: unrecognized error format')
|
||||
call syntastic#log#warn('checker javascript/tern_lint: unrecognized error format (crashed checker?)')
|
||||
endif
|
||||
|
||||
echomsg string(out)
|
||||
@ -453,7 +453,7 @@ function! syntastic#preprocess#vint(errors) abort " {{{2
|
||||
endif
|
||||
endfor
|
||||
else
|
||||
call syntastic#log#warn('checker vim/vint: unrecognized error format')
|
||||
call syntastic#log#warn('checker vim/vint: unrecognized error format (crashed checker?)')
|
||||
endif
|
||||
|
||||
return out
|
||||
|
@ -101,6 +101,7 @@ SYNTAX CHECKERS BY LANGUAGE *syntastic-checkers-lang*
|
||||
Sh.......................................|syntastic-checkers-sh|
|
||||
Slim.....................................|syntastic-checkers-slim|
|
||||
SML......................................|syntastic-checkers-sml|
|
||||
Solidity.................................|syntastic-checkers-solidity|
|
||||
SQL......................................|syntastic-checkers-sql|
|
||||
Stylus...................................|syntastic-checkers-stylus|
|
||||
|
||||
@ -5779,6 +5780,37 @@ Checker options~
|
||||
This checker is initialised using the "makeprgBuild()" function and thus it
|
||||
accepts the standard options described at |syntastic-config-makeprg|.
|
||||
|
||||
==============================================================================
|
||||
SYNTAX CHECKERS FOR SOLIDITY *syntastic-checkers-solidity*
|
||||
|
||||
The following checkers are available for Solidity (filetype "solidity"):
|
||||
|
||||
1. solc.....................|syntastic-solidity-solc|
|
||||
|
||||
------------------------------------------------------------------------------
|
||||
1. solc *syntastic-solidity-solc*
|
||||
|
||||
Name: solc
|
||||
Maintainer: Jacob Cholewa <jacob@cholewa.dk>
|
||||
|
||||
"solc" is a compiler for Ethereum's smart-contract language "Solidity"
|
||||
(https://solidity.readthedocs.io/). See the project's page for details:
|
||||
|
||||
https://github.com/ethereum/solidity
|
||||
|
||||
Checker options~
|
||||
|
||||
This checker is initialised using the "makeprgBuild()" function and thus it
|
||||
accepts the standard options described at |syntastic-config-makeprg|.
|
||||
|
||||
Note~
|
||||
|
||||
You probably also need a plugin to set |filetype| for Solidity files, such as
|
||||
"vim-solidity":
|
||||
|
||||
https://github.com/tomlion/vim-solidity
|
||||
|
||||
|
||||
==============================================================================
|
||||
SYNTAX CHECKERS FOR SQL *syntastic-checkers-sql*
|
||||
|
||||
|
@ -19,7 +19,7 @@ if has('reltime')
|
||||
lockvar! g:_SYNTASTIC_START
|
||||
endif
|
||||
|
||||
let g:_SYNTASTIC_VERSION = '3.7.0-177'
|
||||
let g:_SYNTASTIC_VERSION = '3.7.0-193'
|
||||
lockvar g:_SYNTASTIC_VERSION
|
||||
|
||||
" Sanity checks {{{1
|
||||
|
@ -85,6 +85,7 @@ let s:_DEFAULT_CHECKERS = {
|
||||
\ 'slim': ['slimrb'],
|
||||
\ 'sml': ['smlnj'],
|
||||
\ 'spec': ['rpmlint'],
|
||||
\ 'solidity': ['solc'],
|
||||
\ 'sql': ['sqlint'],
|
||||
\ 'stylus': ['stylint'],
|
||||
\ 'tcl': ['nagelfar'],
|
||||
|
@ -1,7 +1,7 @@
|
||||
"============================================================================
|
||||
"File: dockerfile_lint.vim
|
||||
"Description: Syntax checking plugin for syntastic.vim using dockerfile-lint
|
||||
" (https://github.com/projectatomic/dockerfile-lint).
|
||||
" (https://github.com/projectatomic/dockerfile_lint).
|
||||
"Maintainer: Tim Carry <tim at pixelastic dot com>
|
||||
"License: This program is free software. It comes without any warranty,
|
||||
" to the extent permitted by applicable law. You can redistribute
|
||||
|
@ -1,6 +1,6 @@
|
||||
"============================================================================
|
||||
"File: perl.vim
|
||||
"Description: Syntax checking plugin for syntastic.vim
|
||||
"Description: Syntax checking plugin for syntastic
|
||||
"Maintainer: Anthony Carapetis <anthony.carapetis at gmail dot com>,
|
||||
" Eric Harmon <http://eharmon.net>
|
||||
"License: This program is free software. It comes without any warranty,
|
||||
@ -23,7 +23,7 @@
|
||||
"
|
||||
" let g:syntastic_enable_perl_checker = 1
|
||||
"
|
||||
" References:
|
||||
" Reference:
|
||||
"
|
||||
" - http://perldoc.perl.org/perlrun.html#*-c*
|
||||
|
||||
@ -55,15 +55,15 @@ function! SyntaxCheckers_perl_perl_GetLocList() dict " {{{1
|
||||
call syntastic#log#oneTimeWarn('variable g:syntastic_perl_lib_path should be a list')
|
||||
let includes = split(g:syntastic_perl_lib_path, ',')
|
||||
else
|
||||
let includes = copy(syntastic#util#var('perl_lib_path'))
|
||||
let includes = copy(syntastic#util#var('perl_lib_path', []))
|
||||
endif
|
||||
let shebang = syntastic#util#parseShebang()
|
||||
let extra = join(map(includes, '"-I" . v:val')) .
|
||||
\ (index(shebang['args'], '-T') >= 0 ? ' -T' : '') .
|
||||
\ (index(shebang['args'], '-t') >= 0 ? ' -t' : '')
|
||||
let extra = map(includes, '"-I" . v:val') +
|
||||
\ (index(shebang['args'], '-T') >= 0 ? ['-T'] : []) +
|
||||
\ (index(shebang['args'], '-t') >= 0 ? ['-t'] : [])
|
||||
let errorformat = '%f:%l:%m'
|
||||
|
||||
let makeprg = self.makeprgBuild({ 'args_before': '-c -X ' . extra })
|
||||
let makeprg = self.makeprgBuild({ 'args_before': ['-c', '-X '] + extra })
|
||||
|
||||
let errors = SyntasticMake({
|
||||
\ 'makeprg': makeprg,
|
||||
@ -74,7 +74,7 @@ function! SyntaxCheckers_perl_perl_GetLocList() dict " {{{1
|
||||
return errors
|
||||
endif
|
||||
|
||||
let makeprg = self.makeprgBuild({ 'args_before': '-c -Mwarnings ' . extra })
|
||||
let makeprg = self.makeprgBuild({ 'args_before': ['-c', '-Mwarnings'] + extra })
|
||||
|
||||
return SyntasticMake({
|
||||
\ 'makeprg': makeprg,
|
||||
|
@ -25,11 +25,12 @@ function! SyntaxCheckers_scala_fsc_GetLocList() dict
|
||||
" working directory changing after being started
|
||||
" that's why we better pass an absolute path
|
||||
let makeprg = self.makeprgBuild({
|
||||
\ 'args_after': '-Ystop-after:parser',
|
||||
\ 'args': '-Ystop-after:parser',
|
||||
\ 'fname': syntastic#util#shexpand('%:p') })
|
||||
|
||||
let errorformat =
|
||||
\ '%E%f:%l: %trror: %m,' .
|
||||
\ '%W%f:%l: %tarning:%m,' .
|
||||
\ '%Z%p^,' .
|
||||
\ '%-G%.%#'
|
||||
|
||||
|
@ -0,0 +1,38 @@
|
||||
"============================================================================
|
||||
"File: solc.vim
|
||||
"Description: Solidity syntax checker - using solc
|
||||
"Maintainer: Jacob Cholewa <jacob@cholewa.dk>
|
||||
"License: This program is free software. It comes without any warranty,
|
||||
" to the extent permitted by applicable law. You can redistribute
|
||||
" it and/or modify it under the terms of the Do What The Fuck You
|
||||
" Want To Public License, Version 2, as published by Sam Hocevar.
|
||||
" See http://sam.zoy.org/wtfpl/COPYING for more details.
|
||||
"
|
||||
"============================================================================
|
||||
|
||||
if exists('g:loaded_syntastic_solidity_solc_checker')
|
||||
finish
|
||||
endif
|
||||
let g:loaded_syntastic_solidity_solc_checker = 1
|
||||
|
||||
let s:save_cpo = &cpo
|
||||
set cpo&vim
|
||||
|
||||
function! SyntaxCheckers_solidity_solc_GetLocList() dict
|
||||
let makeprg = self.makeprgBuild({})
|
||||
|
||||
let errorformat = '%f:%l:%c: %trror: %m'
|
||||
|
||||
return SyntasticMake({
|
||||
\ 'makeprg': makeprg,
|
||||
\ 'errorformat': errorformat })
|
||||
endfunction
|
||||
|
||||
call g:SyntasticRegistry.CreateAndRegisterChecker({
|
||||
\ 'filetype': 'solidity',
|
||||
\ 'name': 'solc'})
|
||||
|
||||
let &cpo = s:save_cpo
|
||||
unlet s:save_cpo
|
||||
|
||||
" vim: set sw=4 sts=4 et fdm=marker:
|
Reference in New Issue
Block a user