Skip to content

Hooks

Deterministic guardrails in .claude/hooks/ — they fire on Claude Code events, not by model choice. 9 hooks.

block-local-mutation.sh
PreToolUse

HARD BLOCK on running parallel mutation testing locally. Fanned-out mutation spawns dozens of PHP worker processes and routinely OOM-kills an agent's session/container mid-run — losing in-flight work…

Read more
blog-writing-reminder.sh
UserPromptSubmit

Surfaces the blog conventions at the moment they're needed, instead of carrying them always-on. • prompt is about WRITING / drafting a blog post → inject a pointer to the house voice (docs/agents/blo…

Read more
gate.sh
PreToolUse

Generic hard-gate hook — holds state-changing actions until a gated doc's YAML frontmatter says its exit gate is open. The engine has no skill-specific knowledge. A skill opts in by shipping a plain…

Read more
inject-rules.sh
UserPromptSubmit

Deterministic path-scoped rule loading. Reads the current working set (git status) and prints the .claude/rules/*.md files whose scope matches the changed paths. Claude Code adds this stdout to the m…

Read more
pr-writing-reminder.sh
PreToolUse

When a PR or issue BODY is written via the GitHub MCP tools, inject a pointer to the writing standard (docs/agents/pr-writing.md) so it's surfaced at the moment of writing rather than carried always-…

Read more
rector-tidy.sh
Stop

After the agent finishes, standardise then format the PHP it touched: Rector (structural) first, then Pint (formatting), mirroring `composer tidy`. Scoped to git-dirty PHP files so it stays fast, and…

Read more
session-start.sh
SessionStart

Make the Claude Code on-the-web container match CI so the FULL `composer ci:check` (coverage + mutation, on the right PHP) AND the browser suite (`composer test:browser`) run locally before anything…

Read more
session-title.sh
PostToolUse

Session-title management, in two modes: write — PostToolUse on the `Skill` tool. Records "<emoji> <skill> <args>" for the last *substantive* skill run into .claude/.session-title. emit — called by se…

Read more
suggest-skills.sh
PreToolUse

Nudges the workflow gates at their natural boundaries. It only *injects a reminder* into context; Claude decides whether the change is consequential enough to actually run the skill. Deterministic on…

Read more