verify-then-commit

Runs tests, typecheck, lint, and format checks before allowing any git commit.

Updated Jul 9, 2026
One-click install
npx skills add https://github.com/t-step/bindle-archive --skill verify-then-commit-t-step
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: verify-then-commit
Source: https://github.com/t-step/bindle-archive/tree/main/skills/verify-then-commit
Command: npx skills add https://github.com/t-step/bindle-archive --skill verify-then-commit-t-step

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? It prevents committing unverified code by enforcing a rule that a diff that merely looks correct is not evidence — the project's tests, typecheck, lint, and format checks must actually run and pass before any commit or push happens. ## Core Features & Use Cases - Pre-commit verification gate: Discovers the project's real check commands from the Makefile, package.json, pyproject.toml, or CI workflow and runs tests, typecheck, lint, and format checks in order, committing only when all are green. - Lint vs format distinction: Treats linting (ruff check, eslint) and formatting (ruff format --check, prettier --check, gofmt -l) as separate checks, since a passing linter does not imply a passing formatter. - Hook bypass prevention: Forbids --no-verify, --force, and admin-merge to push a commit through a failing pre-commit hook, and counters common rationalizations like "the subagent said it passed" or "I'll fix CI if it's red". - Use Case: After a subagent or previous session edited code and claims tests pass, run the full gate yourself on the current checkout before committing, rather than trusting the secondhand report. ## Quick Start Before committing my staged changes, run the project's full test, typecheck, lint, and format gate and only commit if everything passes green.

Frequently Asked Questions about verify-then-commit

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I verify code before committing in git?▼

Run the project's full gate — tests, typecheck, lint, and format checks — and commit only if everything passes green. Discover the actual commands from the repo's Makefile, package.json scripts, pyproject.toml, or CI workflow rather than assuming them.

Why does ruff check pass but CI still fails?▼

A linter passing does not imply a formatter passing. ruff check and ruff format --check are separate commands with separate verdicts, and CI often runs both while a Makefile lint target covers only one. Where CI runs a check the Makefile doesn't, CI's list is the gate.

Should I use git commit --no-verify to skip a failing pre-commit hook?▼

No. A failing pre-commit hook is the gate doing its job, and bypassing it with --no-verify, --force, or admin-merge ships a green-looking hash over a red gate. Fix the failure, re-run the full gate, then commit.

Can I trust a subagent's report that tests passed before committing?▼

No. A secondhand report of passing tests is not evidence — verify it yourself on the current checkout by running the gate and watching the output. Reading a diff or trusting a claim catches less than actually executing the checks.

When is it acceptable to commit without running checks?▼

Only for pure documentation or markdown-only changes with no test or type surface, or when the operator explicitly instructs committing without checks. Even then, run the linter if one covers the changed files.