Disable rpmlint by default (#492)

* Disable rpmlint by default as it is not safe.
This commit is contained in:
Jason Tibbitts 2017-04-20 10:55:20 -05:00 committed by w0rp
parent 925f24707f
commit c1a2d26711
3 changed files with 18 additions and 3 deletions

View File

@ -95,7 +95,7 @@ name. That seems to be the fairest way to arrange this table.
| Puppet | [puppet](https://puppet.com), [puppet-lint](https://puppet-lint.com) |
| Python | [flake8](http://flake8.pycqa.org/en/latest/), [mypy](http://mypy-lang.org/), [pylint](https://www.pylint.org/) |
| reStructuredText | [proselint](http://proselint.com/)|
| RPM spec | [rpmlint](https://github.com/rpm-software-management/rpmlint) |
| RPM spec | [rpmlint](https://github.com/rpm-software-management/rpmlint) (disabled by default; see `:help ale-integration-spec`) |
| Ruby | [reek](https://github.com/troessner/reek), [rubocop](https://github.com/bbatsov/rubocop), [ruby](https://www.ruby-lang.org) |
| Rust | [rustc](https://www.rust-lang.org/), cargo (see `:help ale-integration-rust` for configuration instructions) |
| SASS | [sass-lint](https://www.npmjs.com/package/sass-lint), [stylelint](https://github.com/stylelint/stylelint) |

View File

@ -20,11 +20,13 @@ let s:default_ale_linter_aliases = {
" No linters are used for plaintext files by default.
"
" Only cargo is enabled for Rust by default.
" rpmlint is disabled by default because it can result in code execution.
let s:default_ale_linters = {
\ 'csh': ['shell'],
\ 'go': ['go build', 'gofmt', 'golint', 'gosimple', 'go vet', 'staticcheck'],
\ 'help': [],
\ 'rust': ['cargo'],
\ 'spec': [],
\ 'text': [],
\ 'zsh': ['shell'],
\}

View File

@ -1,6 +1,19 @@
===============================================================================
ALE RPM Spec Integration *ale-spec-options*
*ale-integration-spec*
-------------------------------------------------------------------------------
Integration Information
The rpmlint linter is disabled by default, because running rpmlint can
result in the execution of code embedded in the spec file and rpmlint makes
no distinction between checks which are safe to run on untrusted files and
those which are not.
Currently linters must be enabled globally. The rpmlint linter can be
enabled with:
let g:ale_linters = {'spec': ['rpmlint']}
-------------------------------------------------------------------------------
rpmlint *ale-spec-rpmlint*