Merge pull request #91 from w0rp/vint-style-flag

Support Vint style issues, and enabling/disabling them
This commit is contained in:
w0rp 2016-10-11 13:33:18 +01:00 committed by GitHub
commit 6ee42c9a2d
2 changed files with 34 additions and 11 deletions

View File

@ -7,11 +7,20 @@ endif
let g:loaded_ale_linters_vim_vint = 1
" This flag can be used to change enable/disable style issues.
let g:ale_vim_vint_show_style_issues =
\ get(g:, 'ale_vim_vint_show_style_issues', 1)
let s:warning_flag = g:ale_vim_vint_show_style_issues ? '-s' : '-w'
let s:format = '-f "{file_path}:{line_number}:{column_number}: {severity}: {description} (see {reference})"'
call ale#linter#Define('vim', {
\ 'name': 'vint',
\ 'executable': 'vint',
\ 'command': g:ale#util#stdin_wrapper . ' .vim vint -w --no-color ' . s:format,
\ 'command': g:ale#util#stdin_wrapper
\ . ' .vim vint '
\ . s:warning_flag
\ . ' --no-color '
\ . s:format,
\ 'callback': 'ale#handlers#HandleGCCFormat',
\})

View File

@ -10,15 +10,16 @@ CONTENTS *ale-contents*
2. Supported Languages & Tools................|ale-support|
3. Global Options.............................|ale-options|
4. Linter Specific Options....................|ale-linter-options|
4.1. eslint.................................|ale-linter-options-eslint|
4.2. jshint.................................|ale-linter-options-jshint|
4.3. phpcs..................................|ale-linter-options-phpcs|
4.4. html-tidy..............................|ale-linter-options-html-tidy|
4.5. c-gcc..................................|ale-linter-options-c-gcc|
4.6. cpp-gcc................................|ale-linter-options-cpp-gcc|
4.7. fortran-gcc............................|ale-linter-options-fortran-gcc|
4.8. shell..................................|ale-linter-options-shell|
4.9. shellcheck.............................|ale-linter-options-shellcheck|
4.1. eslint................................|ale-linter-options-eslint|
4.2. jshint................................|ale-linter-options-jshint|
4.3. phpcs.................................|ale-linter-options-phpcs|
4.4. html-tidy.............................|ale-linter-options-html-tidy|
4.5. c-gcc.................................|ale-linter-options-c-gcc|
4.6. cpp-gcc...............................|ale-linter-options-cpp-gcc|
4.7. fortran-gcc...........................|ale-linter-options-fortran-gcc|
4.8. shell.................................|ale-linter-options-shell|
4.9. shellcheck............................|ale-linter-options-shellcheck|
4.10. vint..................................|ale-linter-options-vint|
5. API........................................|ale-api|
6. Contact....................................|ale-contact|
@ -432,7 +433,7 @@ g:ale_linters_sh_shell_default_shell *g:ale_linters_sh_shell_default_shell*
-------------------------------------------------------------------------------
4.9. shellchek *ale-linter-options-shellcheck*
4.9. shellcheck *ale-linter-options-shellcheck*
g:ale_linters_sh_shellckeck_exclusions *g:ale_linters_sh_shellckeck_exclusions*
@ -442,6 +443,19 @@ g:ale_linters_sh_shellckeck_exclusions *g:ale_linters_sh_shellckeck_exclusions*
Set this variable to exclude test(s) for shellcheck (-e/--exclude option).
-------------------------------------------------------------------------------
4.10. vint *ale-linter-options-vint*
g:ale_vim_vint_show_style_issues *g:ale_vim_vint_show_style_issues*
Type: |Number|
Default: `1`
This variable will enable/disable style issues for Vint. When this option
is disabled, only warnings and errors which are not purely style issues
will be reported.
===============================================================================
5. API *ale-api*