default_install_hook_types: [pre-commit, pre-push]
repos:
  - repo: https://github.com/astral-sh/ruff-pre-commit
    rev: v0.9.6
    hooks:
      - id: ruff
        args: [--fix]
      - id: ruff-format
  - repo: https://github.com/PyCQA/docformatter
    rev: 06907d0
    hooks:
      - id: docformatter
  - repo: https://github.com/RobertCraigie/pyright-python
    rev: v1.1.394
    hooks:
      - id: pyright
  - repo: https://github.com/adamchainz/blacken-docs
    rev: 1.19.1
    hooks:
      - id: blacken-docs
        additional_dependencies:
          - black>=24.4.2
  - repo: local
    hooks:
      - id: fmt
        name: fmt
        language: system
        types: [rust]
        entry: cargo fmt
        pass_filenames: false
      - id: clippy
        name: clippy
        language: system
        types: [rust]
        entry:
          cargo clippy --all-targets --all-features -- -D warnings -W
          clippy::all -W clippy::cargo -W clippy::complexity -W
          clippy::correctness -W clippy::pedantic -W clippy::perf -W
          clippy::style -W clippy::suspicious
        pass_filenames: false
      - id: doc
        name: doc
        language: system
        types: [rust]
        entry: cargo doc --no-deps --all-features
        pass_filenames: false
  - repo: https://github.com/pre-commit/mirrors-prettier
    rev: v3.1.0
    hooks:
      - id: prettier
