rst: extract a temp var to a query
This commit is contained in:
parent
3049323c74
commit
6acff371af
@ -18,9 +18,8 @@ function! SyntaxCheckers_rst_rst2pseudoxml_IsAvailable()
|
||||
endfunction
|
||||
|
||||
function! SyntaxCheckers_rst_rst2pseudoxml_GetLocList()
|
||||
let s:executable = executable("rst2pseudoxml.py") ? "rst2pseudoxml.py" : "rst2pseudoxml"
|
||||
let makeprg = syntastic#makeprg#build({
|
||||
\ 'exe': s:executable,
|
||||
\ 'exe': s:exe(),
|
||||
\ 'args': '--report=2 --exit-status=1',
|
||||
\ 'tail': syntastic#util#DevNull() })
|
||||
|
||||
@ -33,6 +32,10 @@ function! SyntaxCheckers_rst_rst2pseudoxml_GetLocList()
|
||||
return SyntasticMake({ 'makeprg': makeprg, 'errorformat': errorformat })
|
||||
endfunction
|
||||
|
||||
function s:exe()
|
||||
return executable("rst2pseudoxml.py") ? "rst2pseudoxml.py" : "rst2pseudoxml"
|
||||
endfunction
|
||||
|
||||
call g:SyntasticRegistry.CreateAndRegisterChecker({
|
||||
\ 'filetype': 'rst',
|
||||
\ 'name': 'rst2pseudoxml'})
|
||||
|
Loading…
Reference in New Issue
Block a user