Skip to content

Conversation

@corbt
Copy link
Contributor

@corbt corbt commented Jan 17, 2026

Summary

Replaces the custom run_checks.sh script with prek, a fast Rust-based pre-commit framework.

Changes

  • Add prek as dev dependency for faster, single-binary pre-commit hooks
  • Add .pre-commit-config.yaml with:
    • ruff + ruff-format (from astral-sh/ruff-pre-commit)
    • pyright type checking
    • uv lock --check for lockfile sync verification
    • pytest (manual stage locally, runs in CI)
  • Rename workflow from ruff.yml to prek.yml, now runs all hooks via prek
  • Delete run_checks.sh (superseded by prek hooks)
  • Update docs (CONTRIBUTING.md, AGENT.md) with new workflow

Local Usage

uv sync --group dev
uv run prek install        # optional: install git hooks
uv run prek run --all-files
uv run prek run pytest     # run tests manually

Why prek?

  • Single binary, no Python runtime needed for the hook runner
  • Faster than pre-commit, shared toolchains between hooks
  • Drop-in compatible with existing pre-commit configs
  • Built-in uv integration for Python environments

- Add prek as dev dependency for faster, Rust-based pre-commit hooks
- Add .pre-commit-config.yaml with ruff, pyright, uv.lock check, and pytest hooks
- Rename ruff.yml workflow to prek.yml, now runs all hooks via prek
- pytest runs as manual hook locally but included in CI
- Delete run_checks.sh (superseded by prek hooks)
- Update CONTRIBUTING.md and AGENT.md with new workflow
This enables CI checks for stacked PRs that target non-main branches.
@corbt corbt merged commit beb0315 into main Jan 19, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants