chore(pre-commit): dogfood the shipped pre-commit gate on the maintainer repo#6
Merged
Conversation
Reviewed design for wiring pre-commit into the maintainer repo (gap #1 of the dogfooding-gap audit): a local-only mirror of the shipped config, with ruff run via local `uv run ruff` hooks (locked 0.15.19, no ruff-pre-commit drift), the pytest hook dropped (CI matrix is the enforcer), and hygiene hooks excluding template/. Folds in the adversarial review's amendments (a `setup` bootstrap recipe, a two-stage `precommit` recipe, and the AGENTS.md section).
Task-by-task plan to implement the pre-commit design (gap #1), with per-step verification commands and expected output empirically confirmed by a worktree-isolated dry-run: the four implementation commits land green with a clean tree. Includes a forbid-rej negative check and corrected pre-push hook behavior (end-of-file-fixer/trailing-whitespace inherit a pre-push stage).
This was referenced Jul 7, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Dogfood the pre-commit gate the template ships, adapted to the maintainer repo's own surface (
tests/only, ruff pinned viauv.lock, a CI-only generation-matrix suite). Closes gap #1 of the dogfooding-gap audit (docs/superpowers/plans/2026-07-01-dogfood-gap-audit.md).Changes
.pre-commit-config.yaml: SHA-pinnedpre-commit-hooks(check-merge-conflict; eof-fixer / trailing-whitespace excluded ontemplate/), localuv runruff-check / ruff-format hooks, basedpyright at pre-push, and aforbid-rejcopier-conflict guard.pre-commit>=4,<5dev dep,just setup/just precommitrecipes, and an## Pre-commitsection inAGENTS.md. Design + plan committed underdocs/superpowers/.Testing
just test— full generation matrix, 70 passed (3m 7s); both pre-commit stages green over the whole tree. Pre-push hooks ran on this branch's push (basedpyright correctly skipped — no.pyin the diff).Notes for reviewers
just cinever runs pre-commit); the ruff/basedpyright substance stays enforced by the existinglint/typecheckjobs.uv runhooks (locked 0.15.19) instead of the shippedruff-pre-commit(0.15.18) to kill version drift. The template's own 0.15.18-vs-0.15.19 mismatch is a real template defect, tracked as follow-up in the design's "Out of scope" section.