repos: - repo: https://github.com/pre-commit/pre-commit-hooks rev: v3.4.0 hooks: - id: check-case-conflict - id: check-merge-conflict - id: check-yaml - id: end-of-file-fixer exclude: (cibuildwheel/resources/pinned_docker_images.cfg)|(.svg$) - id: mixed-line-ending - id: trailing-whitespace - repo: https://github.com/PyCQA/isort rev: 5.7.0 hooks: - id: isort - repo: https://github.com/psf/black rev: 20.8b1 hooks: - id: black files: ^bin/update_pythons.py|setup.py$ - repo: https://github.com/pre-commit/mirrors-mypy rev: v0.800 hooks: - id: mypy exclude: ^(bin/|cibuildwheel/resources/).*py$ additional_dependencies: [packaging] args: ["--python-version=3.6", "--ignore-missing-imports", "--scripts-are-modules"] - id: mypy name: mypy 3.7+ on bin/ files: ^bin/.*py$ additional_dependencies: [packaging] args: ["--python-version=3.7", "--ignore-missing-imports", "--scripts-are-modules"] - repo: https://github.com/asottile/pyupgrade rev: v2.9.0 hooks: - id: pyupgrade args: ["--py36-plus"] - repo: https://gitlab.com/pycqa/flake8 rev: 3.8.4 hooks: - id: flake8 exclude: cibuildwheel/resources/ additional_dependencies: [flake8-bugbear] # The original pybind11 checks for a few C++ style items - repo: local hooks: - id: disallow-caps name: Disallow improper capitalization language: pygrep entry: PyBind|Numpy|Cmake|Github types: - markdown