Standard checker: allow generic standard frontends.

This commit is contained in:
LCD 47 2015-11-03 16:40:58 +02:00
parent 943923433c
commit 9f599a1610
2 changed files with 10 additions and 2 deletions

View File

@ -19,7 +19,7 @@ if has('reltime')
lockvar! g:_SYNTASTIC_START
endif
let g:_SYNTASTIC_VERSION = '3.7.0-22'
let g:_SYNTASTIC_VERSION = '3.7.0-23'
lockvar g:_SYNTASTIC_VERSION
" Sanity checks {{{1

View File

@ -14,14 +14,22 @@ if exists('g:loaded_syntastic_javascript_standard_checker')
endif
let g:loaded_syntastic_javascript_standard_checker = 1
if !exists('g:syntastic_javascript_eslint_generic')
let g:syntastic_javascript_standard_generic = 0
endif
let s:save_cpo = &cpo
set cpo&vim
function! SyntaxCheckers_javascript_standard_IsAvailable() dict
if g:syntastic_javascript_standard_generic
call self.log('generic standard, exec =', self.getExec())
endif
if !executable(self.getExec())
return 0
endif
return syntastic#util#versionIsAtLeast(self.getVersion(), [2, 6, 1])
return g:syntastic_javascript_standard_generic || syntastic#util#versionIsAtLeast(self.getVersion(), [2, 6, 1])
endfunction
function! SyntaxCheckers_javascript_standard_GetLocList() dict