Change Python project root dir detection for flake8 configuration

The official configuration files for `flake8` are `.flake8`, `tox.ini`,
and `setup.cfg`.

After investigation, it is safe to remove `flake8.cfg` as it appears to
only exist as a typo in other tooling documentation (e.g.,
`python-language-server`).

Even though no linters automatically read `.flake8rc`, it is kept in
case projects may be using it for detecting the projects root directory.
This commit is contained in:
Eric N. Vander Weele 2019-05-18 09:42:19 -04:00
parent 57b9d8bc0e
commit 57736cdccc
2 changed files with 2 additions and 2 deletions

View File

@ -25,7 +25,7 @@ function! ale#python#FindProjectRootIni(buffer) abort
\|| filereadable(l:path . '/tox.ini')
\|| filereadable(l:path . '/mypy.ini')
\|| filereadable(l:path . '/pycodestyle.cfg')
\|| filereadable(l:path . '/flake8.cfg')
\|| filereadable(l:path . '/.flake8')
\|| filereadable(l:path . '/.flake8rc')
\|| filereadable(l:path . '/pylama.ini')
\|| filereadable(l:path . '/pylintrc')

View File

@ -29,7 +29,7 @@ ALE will look for configuration files with the following filenames. >
tox.ini
mypy.ini
pycodestyle.cfg
flake8.cfg
.flake8
.flake8rc
pylama.ini
pylintrc