diff options
author | Yining <zhang.yining@gmail.com> | 2023-01-27 12:24:18 +1100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-01-27 10:24:18 +0900 |
commit | b6f6d84c25169744f43db6d0ee296ee44eb78d91 (patch) | |
tree | 7df3bc78af81f76a7ed2813f90ccae96a8d0e16b /doc/ale-python.txt | |
parent | 26c79014f52b0306ec619666bc73766f22621edb (diff) | |
download | ale-b6f6d84c25169744f43db6d0ee296ee44eb78d91.zip |
add: pycln as a python linter and fixer (#4415)
this commit adds pycln as a Python linter and fixer, together with some
tests and documentation. It addresses #4340
pycln repo: https://github.com/hadialqattan/pycln
Diffstat (limited to 'doc/ale-python.txt')
-rw-r--r-- | doc/ale-python.txt | 72 |
1 files changed, 72 insertions, 0 deletions
diff --git a/doc/ale-python.txt b/doc/ale-python.txt index 07f54db8..aad64b1d 100644 --- a/doc/ale-python.txt +++ b/doc/ale-python.txt @@ -581,6 +581,78 @@ g:ale_python_prospector_auto_poetry *g:ale_python_prospector_auto_poetry* =============================================================================== +pycln *ale-python-pycln* + +g:ale_python_pycln_change_directory *g:ale_python_pycln_change_directory* + *b:ale_python_pycln_change_directory* + Type: |Number| + Default: `1` + + If set to `1`, `pycln` will be run from a detected project root, per + |ale-python-root|. if set to `0` or no project root detected, + `pycln` will be run from the buffer's directory. + + +g:ale_python_pycln_executable *g:ale_python_pycln_executable* + *b:ale_python_pycln_executable* + Type: |String| + Default: `'pycln'` + + See |ale-integrations-local-executables| + + Set this to `'pipenv'` to invoke `'pipenv` `run` `pycln'`. + Set this to `'poetry'` to invoke `'poetry` `run` `pycln'`. + + +g:ale_python_pycln_options *g:ale_python_pycln_options* + *b:ale_python_pycln_options* + Type: |String| + Default: `''` + + This variable can be changed to add command-line arguments to the pycln + invocation. + + For example, to select/enable and/or disable some error codes, + you may want to set > + let g:ale_python_pycln_options = '--expand-stars' + + +g:ale_python_pycln_config_file *g:ale_python_pycln_config_file* + *b:ale_python_pycln_config_file* + Type: |String| + Default: `''` + + Use this variable to set the configuration file. + If `'--config' ` is found in the |g:ale_python_pycln_options|, then that + option value will override the value in this variable. + +g:ale_python_pycln_use_global *g:ale_python_pycln_use_global* + *b:ale_python_pycln_use_global* + Type: |Number| + Default: `get(g:, 'ale_use_global_executables', 0)` + + See |ale-integrations-local-executables| + + +g:ale_python_pycln_auto_pipenv *g:ale_python_pycln_auto_pipenv* + *b:ale_python_pycln_auto_pipenv* + Type: |Number| + Default: `0` + + Detect whether the file is inside a pipenv, and set the executable to `pipenv` + if true. This is overridden by a manually-set executable. + + +g:ale_python_pycln_auto_poetry *g:ale_python_pycln_auto_poetry* + *b:ale_python_pycln_auto_poetry* + Type: |Number| + Default: `0` + + Detect whether the file is inside a poetry, and set the executable to `poetry` + if true. This is overridden by a manually-set executable. + + +=============================================================================== pycodestyle *ale-python-pycodestyle* g:ale_python_pycodestyle_executable *g:ale_python_pycodestyle_executable* |