Skip to content

fix(p12): runbook install_time_config wrongly claimed hooks deploy to ~/.claude/hooks/#425

Merged
lantiscooperdev merged 1 commit into
mainfrom
fix/p12-runbook-install-config-doc
Jun 27, 2026
Merged

fix(p12): runbook install_time_config wrongly claimed hooks deploy to ~/.claude/hooks/#425
lantiscooperdev merged 1 commit into
mainfrom
fix/p12-runbook-install-config-doc

Conversation

@lantisprime

Copy link
Copy Markdown
Owner

Problem

The shared renderConfigBlock generator hardcoded install_time_config: hooks deployed under /.claude/hooks/byinstall.mjs --install-hooks``, emitted into every plugin runbook §10 (claude-code + opencode). That contradicts Principle 12 (enforcement is per-project, never global) and the actual installer: install.mjs:1336 roots `userHooksDir` at `/.claude/hooks` (not `os.homedir()`), and enforcement deploys per-project under `/.claude/` or `/.opencode/`, never `/.claude/`.

Caught during the P5 post-merge review when the deploy scope was being audited.

Fix

  • scripts/validate-plugin-registry.mjs renderConfigBlock: corrected the line to state the per-project / never-global truth, citing Principle 12.
  • Regenerated the §10 CONFIG block in plugins/claude-code/runbooks/enforcement.md and plugins/opencode/runbooks/enforcement.md to byte-match the generator (M7f).

Verification

node tests/test-plugin-registry.mjs -> 200/0 (M7f byte-match holds for both runbooks). Old ~/.claude/hooks/ string removed everywhere; corrected line present in generator + both runbooks.

🤖 Generated with Claude Code

…o ~/.claude/hooks/

The shared renderConfigBlock generator hardcoded "hooks deployed under
`~/.claude/hooks/` by `install.mjs --install-hooks`", emitted into every
plugin runbook's §10. That contradicts Principle 12 and the actual
installer: install.mjs:1336 roots userHooksDir at <project>/.claude/hooks
(not os.homedir()), and enforcement deploys per-project under
<project>/.claude/ or <project>/.opencode/, NEVER ~/.claude/.

- validate-plugin-registry.mjs renderConfigBlock: corrected the line to
  state the per-project / never-global truth (Principle 12).
- regenerated the §10 CONFIG block in both plugins/claude-code and
  plugins/opencode runbooks to byte-match (M7f).

test-plugin-registry 200/0.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

@lantiscooperdev lantiscooperdev left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review — P12 runbook install_time_config doc fix

Verified against the actual installer, not the runbook text:

  • install.mjs:1336 defines userHooksDir = path.join(projectDir, '.claude', 'hooks') — project-rooted, never os.homedir(). The old runbook line "hooks deployed under ~/.claude/hooks/" was factually wrong and P12-inconsistent.
  • The corrected line states the per-project / never-global truth and cites Principle 12; it is now harness-accurate for both .claude/ (claude-code) and .opencode/ (opencode).
  • Generator and both runbooks carry the identical corrected string; test-plugin-registry 200/0 confirms the §10 M7f byte-match holds for both.

Scope is doc/string only; no behavior change. No blockers. Deferring merge approval to a human.

@lantiscooperdev lantiscooperdev merged commit a7f66c9 into main Jun 27, 2026
3 checks passed
lantiscooperdev pushed a commit that referenced this pull request Jun 27, 2026
P5 (OpenCode enforcement plugin) merged via #424 (`f5dbaef`) + doc fix
#425 (`a7f66c9`). Flip the stale `queued` P5 status in the three places
that track it, mirroring #423's P4-DONE sync:

- RFC-008/README.md phase matrix: the shared P5-P7 row now reads
  P5 DONE; P6 / P7 queued (Codex, Pi Agent still pending).
- RFC body phase-index stub (:1220): same split.
- P5-P7-tool-plugins.md status line: P5 DONE, P6/P7 queued.

P6/P7 stay queued (shared row/file). RFC-008 remains `accepted` at the
registry level (not all phases shipped), so docs/rfcs/_index.json +
README.md are unchanged; em-rfc-validate passes (8/8/8 consistent).
Rule 10 doc-sync; no code change.

Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
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