2018-09-17 07:15:50 +00:00
|
|
|
repos:
|
2021-04-04 08:00:52 +00:00
|
|
|
- repo: https://github.com/pre-commit/pre-commit-hooks
|
|
|
|
rev: v3.4.0
|
|
|
|
hooks:
|
|
|
|
- id: trailing-whitespace
|
|
|
|
exclude: "tests/functional/t/trailing_whitespaces.py"
|
|
|
|
- id: end-of-file-fixer
|
|
|
|
exclude: "tests/functional/m/missing/missing_final_newline.py|tests/functional/t/trailing_newlines.py"
|
2020-09-20 10:11:26 +00:00
|
|
|
- repo: https://github.com/myint/autoflake
|
|
|
|
rev: v1.4
|
2018-09-17 07:15:50 +00:00
|
|
|
hooks:
|
2020-09-20 10:11:26 +00:00
|
|
|
- id: autoflake
|
|
|
|
exclude: &fixtures tests/functional/|tests/input|tests/extensions/data|tests/regrtest_data/|tests/data/
|
|
|
|
args:
|
|
|
|
- --in-place
|
|
|
|
- --remove-all-unused-imports
|
|
|
|
- --expand-star-imports
|
|
|
|
- --remove-duplicate-keys
|
|
|
|
- --remove-unused-variables
|
2021-02-21 12:20:34 +00:00
|
|
|
- repo: https://github.com/asottile/pyupgrade
|
2021-04-04 08:00:52 +00:00
|
|
|
rev: v2.11.0
|
2021-02-21 12:20:34 +00:00
|
|
|
hooks:
|
|
|
|
- id: pyupgrade
|
|
|
|
args: [--py36-plus]
|
|
|
|
exclude: *fixtures
|
2020-09-10 20:52:59 +00:00
|
|
|
- repo: https://github.com/PyCQA/isort
|
2021-04-04 08:00:52 +00:00
|
|
|
rev: 5.8.0
|
2019-03-09 08:05:14 +00:00
|
|
|
hooks:
|
|
|
|
- id: isort
|
2020-09-20 10:11:26 +00:00
|
|
|
- repo: https://github.com/ambv/black
|
|
|
|
rev: 20.8b1
|
|
|
|
hooks:
|
|
|
|
- id: black
|
|
|
|
args: [--safe, --quiet]
|
|
|
|
exclude: *fixtures
|
2021-03-06 09:16:30 +00:00
|
|
|
- repo: https://github.com/Pierre-Sassoulas/black-disable-checker/
|
2021-04-04 08:00:52 +00:00
|
|
|
rev: 1.0.0
|
2021-03-06 09:16:30 +00:00
|
|
|
hooks:
|
|
|
|
- id: black-disable-checker
|
2021-04-04 08:00:52 +00:00
|
|
|
- repo: https://gitlab.com/pycqa/flake8
|
|
|
|
rev: 3.9.0
|
|
|
|
hooks:
|
|
|
|
- id: flake8
|
|
|
|
exclude: *fixtures
|
2020-11-14 22:33:51 +00:00
|
|
|
- repo: local
|
|
|
|
hooks:
|
|
|
|
- id: pylint
|
|
|
|
name: pylint
|
|
|
|
entry: pylint
|
|
|
|
language: system
|
|
|
|
types: [python]
|
2021-03-07 15:49:57 +00:00
|
|
|
args: ["-rn", "-sn", "--rcfile=pylintrc", "--load-plugins=pylint.extensions.docparams"]
|
|
|
|
# disabled plugins: pylint.extensions.mccabe
|
2020-12-14 12:48:28 +00:00
|
|
|
exclude: tests/functional/|tests/input|tests/extensions/data|tests/regrtest_data/|tests/data/|doc/
|
2021-03-05 15:53:02 +00:00
|
|
|
- id: fix-documentation
|
|
|
|
name: Fix documentation
|
|
|
|
entry: python3 -m script.fix_documentation
|
|
|
|
language: system
|
|
|
|
types: [text]
|
|
|
|
files: ^(ChangeLog|doc/whatsnew/\d+\.\d+\.rst)
|
2021-02-06 06:53:19 +00:00
|
|
|
- repo: https://github.com/pre-commit/mirrors-mypy
|
2021-02-21 22:17:11 +00:00
|
|
|
rev: v0.812
|
2021-02-06 06:53:19 +00:00
|
|
|
hooks:
|
|
|
|
- id: mypy
|
|
|
|
name: mypy
|
|
|
|
entry: mypy
|
|
|
|
language: python
|
2021-02-14 21:23:24 +00:00
|
|
|
types: [python]
|
2021-02-06 06:53:19 +00:00
|
|
|
args: ["--ignore-missing-imports", "--scripts-are-modules"]
|
|
|
|
require_serial: true
|
|
|
|
additional_dependencies: []
|
|
|
|
exclude: tests/functional/|tests/input|tests/extensions/data|tests/regrtest_data/|tests/data/|doc/|bin/
|