(1) Checkers now have an _exec attribute, and an accessor getExec().
(2) CreateAndRegisterChecker() initializes _exec from an optional argument
'exec'. If this argument is missing, 'name' is used instead.
(3) Functions SyntaxCheckers_*_IsAvailable() are now dictionary functions.
(4) Functions SyntaxCheckers_*_IsAvailable() are now optional. When
they are missing, they are assumed to return executable(expand(self.getExec())).
(5) Argument 'exe' of function syntastic#makeprg#build() is now optional.
If this argument is missing, expand(self.getExec()) is used to set checker
executables.
Make SyntaxCheckers_*_GetLocList() dictionary functions.
Pass a reference to the current checker to syntastic#makeprg#build().
Add an optional 'redirect' argument to CreateAndRegisterChecker().
Change the sh checker to use the new dictionary functions.
Add a new registry method getLocListRaw() (needed for the sh checker).
JSHint has a secondary error format that includes a number related to the error message.
E.g. The normal error format is something like:
.\Foo.js: line 2, col 5, Missing semicolon. (W033)
But the secondary error format includes a number in parentheses:
.\Foo.js: line 3, col 4, Blocks are nested too deeply. (2) (W073)"
I've changed the errorformat to read the message until it hits a space, instead of a period, so that these errors are included.
pass `jshint` the `--verbose` option to get 'W' or 'E' indicating
whether something is a warning or an error.
NOTE: this was tested with jshint 1.1.0 installed with `npm install
jshint`
update makeprg builder:
* it now accepts `fname`, `tail`, and `post_args` params.
* add some doc above syntastic#makeprg#build
* update a bunch of checkers to use the new params
Still have quite a few checkers that arent using makeprg#build.
Including all c* and a few other c-like checkers. And PHP.
Not to worried about c* as these checkers are complicated and probably
justify having their own logic to build makeprgs.
Make all the easy updates. There are still quite a few to do, but in
doing these ones I can see that syntastic#makeprg#build() needs to
accept a few more options. Namely:
* "postargs" that appear after the filename
* "tail" that appears after everything - used for things like
redirecting output and piping to grep/sed/etc
* the filename itself - only the java checkers needed this since they
specify the directory of the file to check as well
There are still a few other things to do as well:
* remove the options from the checkers that are now provided by
syntastic#makeprg#build implicitly - i.e. the checker exe and args.
* also, we need to doc the above implicit checker options
That variable specify the file which contains a list of filename that
Closure Compiler processes at once.
It can be useful for a project using 'require' statement like node.js.
* remove the public SyntasticHighlightErrors() function
* shift the above code into s:HighlightErrors(). This is called
automatically if g:syntastic_enable_highlighting is set
* to get the highlight regex we just look for a function called
Syntastic_<filetype>_GetHighlightRegex
* to force this function to be called, each error item must have the
'force_highlight_callback' key set
This code has one important functional change: now errors are *always*
highlighted if possible whereas previously they were only highlighted if
a call to SyntasticHighlightErrors was made.
The jslint guys have changed their error format again. Update the syntax
checker to handle it.
Currently jslint outputs a "use strict" error if a function doesnt have
'use strict' at the top. This is not good for our purposes, so just
filter this out for now.
The js syntax checker was 4 checkers stuffed into 1 file. Now it is
broken down so that each checker is in its own file inside
syntax_checkers/javascript/ while syntax_checkers/javascript.vim just
determines which file to source.
Change the names of the global js checker config variables so that
they all start with "syntastic_javascript_". This is purely for
namespacing.
Remove some unneeded logic around the config variables too. Not sure how
it got in there, but it was more confusing than helpful without offering
any benefits...