# See https://pre-commit.com for more information
# See https://pre-commit.com/hooks.html for more hooks
%YAML 1.2
---
exclude: "site/.*"
default_install_hook_types: [pre-commit, commit-msg]
default_stages: [pre-commit]
repos:
  - repo: https://github.com/pre-commit/pre-commit-hooks
    rev: v6.0.0
    hooks:
      - id: trailing-whitespace
      - id: end-of-file-fixer
      - id: check-yaml
      - id: check-added-large-files
      - id: check-case-conflict
      - id: check-merge-conflict
      - id: check-toml
      - id: debug-statements
  - repo: https://github.com/asottile/add-trailing-comma
    rev: v4.0.0
    hooks:
      - id: add-trailing-comma
  - repo: https://github.com/astral-sh/ruff-pre-commit
    #  Ruff version.
    rev: v0.14.4
    hooks:
      #  Run the linter.
      - id: ruff
        types_or: [python, pyi]
      #  Run the formatter.
      - id: ruff-format
        types_or: [python, pyi]
        #  options: ignore one line things [E701]
  - repo: https://github.com/adrienverge/yamllint
    rev: v1.37.1
    hooks:
      - id: yamllint
        name: yamllint
        description: This hook runs yamllint.
        entry: yamllint
        language: python
        types: [file, yaml]
        args: ['-d', "{\
          extends: default,\
          rules: {\
            colons: { max-spaces-after: -1 }\
          }\
        }"]
  - repo: https://github.com/rhysd/actionlint
    rev: v1.7.8
    hooks:
      - id: actionlint
        name: Lint GitHub Actions workflow files
        description: Runs actionlint to lint GitHub Actions workflow files
        language: golang
        types: ["yaml"]
        files: ^\.github/workflows/
        entry: actionlint
  - repo: https://github.com/jorisroovers/gitlint
    rev: v0.19.1
    hooks:
      - id: gitlint
        name: gitlint
        description: Checks your git commit messages for style.
        language: python
        additional_dependencies: ["./gitlint-core[trusted-deps]"]
        entry: gitlint
        args: [--staged, --msg-filename]
        stages: [commit-msg]
  - repo: https://github.com/crate-ci/typos
    rev: v1
    hooks:
      - id: typos
  - repo: https://github.com/Yelp/detect-secrets
    rev: v1.5.0
    hooks:
      - id: detect-secrets
        name: Detect secrets
        language: python
        entry: detect-secrets-hook
        args: ['']
  - repo: https://github.com/rvben/rumdl-pre-commit
    rev: v0.0.173  # Use the latest release tag
    hooks:
      - id: rumdl
        # To only check (default):
        # args: []
        # To automatically fix issues:
        # args: [--fix]
  - repo: https://github.com/RobertCraigie/pyright-python
    rev: v1.1.407   # pin a tag; latest as of 2025-10-01
    hooks:
      - id: pyright
