Fun fact: ALE doesn't check your code. ALE doesn't produce any warnings.
What ALE does do, it runs code checkers that do the actual code checking and aggregates their output. Like that co-worker you hate, it let's others do the work and passes the results as its own.
The question doesn't say but it's pretty obvious this one's about Python.
The first (and almost only) ALE command you need to know is :ALEInfo
. It will show which tools were run and the warnings they reported. It's a lot of text and you will need to scroll down for a bit.
In my example, I seewrote a line of Python code, ran :ALEInfo
and saw
C0103 (invalid-name) Variable name "camelCase" doesn't conform to snake_case naming style
reported by pylint
.
You can Google how to shut pylint
up.
I'll show two ways. You can set a variable for ALE to forward to pylint
:let g:ale_python_pylint_options='--disable=C0103'
which will work within Vim for all your Python code.
The alternative is to create a simple .pylintrc
like this one
[SECTION MANDATORY BUT IGNORED]
disable=C0103
This can be per-project or globally and will prevent the warning independently from Vim.
Either way, the warning is gone.
When in Python, do as the Pythons do
I'd like to emphasize that PEP-8 wantsdemands snake_case so it's better to use snake_case identifiers instead of disabling the warning. If it was my repo, I'd bluntly reject such code.