dot-files/vim/.vim/ftplugin/python.vim
Bruno BELANYI 1944ed578d [ADD][VIM] Use pyls in Pipenv with automatically
ALE can detect if the file you're currently editing is inside a Pipenv
environment, and use the pyls inside your environment to have access to
module definitions.

This doesn't launch pyls inside Pipenv when there's no environment
active for your file.
2019-10-19 05:46:29 +02:00

22 lines
626 B
VimL

" Use my desired ALE fixers for python
let b:ale_fixers=[ 'black', 'isort' ]
" Use my desired ALE linters for python
let b:ale_linters=[ 'flake8', 'mypy', 'pylint', 'pyls' ]
"let b:ale_python_pyls_executable='pyls'
let b:ale_python_pyls_auto_pipenv=1
" Disable pycodestyle checks from pyls because I'm already using flake8
let b:ale_python_pyls_config={
\ 'pyls': {
\ 'plugins': {
\ 'pycodestyle': {
\ 'enabled': v:false
\ },
\ },
\ },
\ }
" Change max length of a line to 88 for this buffer to match black's settings
setlocal colorcolumn=88