diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index fa9b8c0..7a14aae 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,19 +1,37 @@ --- repos: - - repo: https://github.com/pre-commit/pre-commit-hooks.git + - repo: https://github.com/pre-commit/pre-commit-hooks rev: v2.3.0 # Use the ref you want to point at hooks: - id: trailing-whitespace - id: check-yaml - id: end-of-file-fixer - - id: flake8 - id: trailing-whitespace - id: check-executables-have-shebangs - repo: https://github.com/python/black - rev: 19.3b0 + rev: 21.7b0 hooks: - id: black - - repo: https://gitlab.com/pycqa/flake8.git - rev: 3.7.8 + - repo: https://github.com/pycqa/flake8 + rev: 3.9.2 hooks: - id: flake8 + - repo: https://github.com/pre-commit/mirrors-mypy + rev: v0.910 + hooks: + - id: mypy + # empty args needed in order to match mypy cli behavior + args: [] + entry: mypy doc8/ + pass_filenames: false + additional_dependencies: + - types-mock + - types-setuptools + - types-docutils + - types-toml + # TODO: activate pylint + # - repo: https://github.com/PyCQA/pylint + # rev: v2.9.3 + # hooks: + # - id: pylint + # additional_dependencies: [] diff --git a/mypy.ini b/mypy.ini new file mode 100644 index 0000000..07afbee --- /dev/null +++ b/mypy.ini @@ -0,0 +1,11 @@ +[mypy-pbr] +ignore_missing_imports = True + +[mypy-restructuredtext_lint] +ignore_missing_imports = True + +[mypy-stevedore] +ignore_missing_imports = True + +[mypy-testtools] +ignore_missing_imports = True