# See https://pre-commit.com for more information # See https://pre-commit.com/hooks.html for more hooks fail_fast: false default_language_version: python: python3 default_stages: - commit - push minimum_pre_commit_version: 2.7.1 repos: - repo: https://github.com/ambv/black rev: 23.7.0 hooks: - id: black - repo: https://github.com/timothycrosley/isort rev: 5.12.0 hooks: - id: isort additional_dependencies: [toml] - repo: https://github.com/snok/pep585-upgrade rev: v1.0 hooks: - id: upgrade-type-hints - repo: https://github.com/pre-commit/pre-commit-hooks rev: v4.4.0 hooks: - id: check-docstring-first - id: end-of-file-fixer - id: check-added-large-files - id: mixed-line-ending - id: trailing-whitespace exclude: ^.bumpversion.cfg$ - id: check-merge-conflict - id: check-case-conflict - id: check-symlinks - id: check-yaml args: [--unsafe] - id: check-ast - id: fix-encoding-pragma args: [--remove] # for Python3 codebase, it's not necessary - id: requirements-txt-fixer - repo: https://github.com/pre-commit/pygrep-hooks rev: v1.10.0 hooks: - id: python-no-eval - id: python-use-type-annotations - id: python-check-blanket-noqa - id: rst-backticks - id: rst-directive-colons - id: rst-inline-touching-normal