Skip to content
.pre-commit-config.yaml 1.74 KiB
Newer Older
default_stages: [commit]
repos:

- repo: meta
  hooks:
  - id: check-hooks-apply

- repo: https://github.com/pre-commit/pre-commit-hooks
  hooks:
  - id: check-added-large-files
  - id: check-case-conflict
  - id: check-docstring-first
  - id: check-merge-conflict
  - id: check-yaml
  - id: debug-statements
  - id: destroyed-symlinks
  - id: end-of-file-fixer
  - id: fix-byte-order-marker
  - id: fix-encoding-pragma
    args: [--remove]
  - id: mixed-line-ending
    args: [--fix=lf]
  - id: trailing-whitespace
    exclude_types: [markdown, plain-text]

- repo: https://github.com/jorisroovers/gitlint
  hooks:
  - id: gitlint

- repo: https://code.kodo.org.uk/dom/pre-commit-hooks
  hooks:
  - id: check-executable-modes
  - id: check-for-squash
  - id: copyright-notice
    args: [--min-size=1]
    exclude: setup\.py
  - id: protect-first-parent

- repo: https://github.com/pre-commit/pygrep-hooks
  hooks:
  - id: python-no-eval
  - id: python-no-log-warn
  - id: python-use-type-annotations

- repo: https://github.com/hakancelikdev/unimport
  rev: 1.2.1
  hooks:
  - id: unimport
    args: [--remove, --exclude=types.py|__init__.py]
    stages: [commit, manual]
- repo: https://github.com/pycqa/isort
  rev: 5.13.2
  hooks:
  - id: isort
    stages: [commit, manual]

- repo: https://github.com/asottile/add-trailing-comma
  hooks:
  - id: add-trailing-comma
    args: [--py36-plus]
    stages: [commit, manual]
Dom Sekotill's avatar
Dom Sekotill committed
- repo: https://github.com/pre-commit/mirrors-mypy
Dom Sekotill's avatar
Dom Sekotill committed
  hooks:
  - id: mypy
    args: [--config-file=setup.cfg]
Dom Sekotill's avatar
Dom Sekotill committed
    additional_dependencies: [anyio, trio-typing]
    exclude: setup\.py|test_.*