Test it, then ship it
Every preset you clicked in this tutorial is a test case, and hooks carry their tests inline. The widget below shows page one’s guard again — this time with its tests block.
uvx capt-hook test runs every hook’s cases through the real dispatch — the same engine the widgets here were verified against:
A hook without tests is a regex you’re hoping about. A hook with tests fails your CI when someone loosens the pattern — run uvx capt-hook test --json in a workflow and a regressed guard breaks the build, not the incident review.
One thing the widgets couldn’t show you: hooks can ask a model. When no pattern can decide — “is this SQL migration destructive?” — llm_gate hands the verdict to an LLM with your rubric. Here’s a recorded run:
That’s the tour. The real thing is one command away:
uvx capt-hook initinit scaffolds .claude/hooks/ with a starter hook and wires Claude Code’s settings. The quickstart takes it from there — same five minutes, your repo this time.