← Files Dataiku HeadlessARCHIVED FILE

.pre-commit-config.yaml

1.57 KB · Nov 27, 2026 · 19:32 UTC

↓ Download file

# Pre-commit hooks for dataiku-headless.
#
#   uv run pre-commit install --install-hooks   # enable on your clone (pre-commit + commit-msg)
#   uv run pre-commit run --all-files            # run every hook against the whole tree
#
# Hooks are pinned; bump them with `uv run pre-commit autoupdate`.
default_install_hook_types: [pre-commit, commit-msg]

repos:
  # General file hygiene.
  - repo: https://github.com/pre-commit/pre-commit-hooks
    rev: v5.0.0
    hooks:
      - id: trailing-whitespace
        args: [--markdown-linebreak-ext=md]
      - id: end-of-file-fixer
      - id: check-yaml
      - id: check-toml
      - id: check-json
      - id: check-merge-conflict
      - id: check-case-conflict
      - id: check-added-large-files
        args: [--maxkb=1024]
      - id: detect-private-key
      - id: mixed-line-ending
        args: [--fix=lf]

  # Ruff: lint (and autofix) using the same rule set CI enforces.
  # `ruff-format` is intentionally NOT enabled — it would reformat 32 files.
  # To opt in later, uncomment the ruff-format hook and commit the reformat.
  - repo: https://github.com/astral-sh/ruff-pre-commit
    rev: v0.15.16
    hooks:
      - id: ruff-check
        args: [--fix]
      - id: ruff-format

  # Keep uv.lock in sync with pyproject.toml.
  - repo: https://github.com/astral-sh/uv-pre-commit
    rev: 0.9.10
    hooks:
      - id: uv-lock

  # Validate commit messages against Conventional Commits (drives commitizen versioning).
  - repo: https://github.com/commitizen-tools/commitizen
    rev: v4.16.3
    hooks:
      - id: commitizen
        stages: [commit-msg]

SHA-256: 05a96ba6d59de85c010cf61d681c98de0300e2e3805114ec49b1f26124dded2b