install-hooks
X-7 per §23 — installs the packaged Claude Code hooks bundle (Stop, PreToolUse, PostToolUse, SessionStart subset) plus slash commands, agents, and detectors into a target settings.json. Idempotent; emits uninstall metadata so /uninstall-cleanup (O-3) can restore prior state.
- License 许可
- Apache-2.0
- 最近更新
- 2026-11-09
- Stars
- ★ 0
- Forks
- 0
01 前言 Front Matter
- name
- install-hooks
- paths
- [ "**/*" ]
- description
- X-7 per §23 — installs the packaged Claude Code hooks bundle (Stop, PreToolUse, PostToolUse, SessionStart subset) plus slash commands, agents, and detectors into a target settings.json. Idempotent; emits uninstall metadata so /uninstall-cleanup (O-3) can restore prior state.
- budget_impact_estimate
- 0 tokens (mechanical settings.json patching).
03 SKILL.md 正文
X-7 installable hooks bundle (§23 amendment)
Writes packaged hooks + slash commands + agents + detectors to the
target settings.json. Uninstall metadata block stamped at install
time so the cleanup path (O-3) can restore prior state without
auto-deleting audit-log or evidence directories.
Invocation
/install-hooks [--scope user|project] [--include <component>...] [--dry-run] [--force]
--scope user|project— install to~/.claude/settings.json(user) or.claude/settings.json(project). Default:project.--include <component>— install only this component (repeatable). Components:hooks,commands,agents,detectors.--dry-run— emit plan; no settings.json writes (per §2.14).--force— override the conflict refusal when target already has conflicting hook scripts. Logged to C-4 with conflict diff.
Uninstall metadata block
{
"tdd_pro_installed_at": "<ISO 8601>",
"tdd_pro_components": ["hooks", "commands", "..."],
"tdd_pro_version": "<semver>",
"tdd_pro_signature": "<sha256>"
}
Idempotency
Re-running with no version change is a no-op. On version change,
runs the appropriate migrations/<from>-to-<to>.sh per O-3.
Cross-references
- §23 v1.9.1 amendment (this skill)
- O-3 /uninstall-cleanup
- C-4 audit log
- §2.14 destructive command dry-run subjects
04 同仓库更多 Skills
test-first-extract
Use when the user asks to EXTRACT or RELOCATE existing code into its own file, module, or component ("extract X", "split out Y", "pull Z into its own file", "decompose god-file"). NOT for net-new features (use tdd-feature-build) or behavior changes (use fix-bug). Enforces the 9-step extraction with isolated unit tests + integration regression tests as a two-tier safety net.
tdd-feature-build
Use when the user describes a NEW feature to add ("add X to Y", "implement Z", "build a feature that…", "make it possible to…"). Enforces TDD — failing test first, minimum code to pass, refactor. Refuses to ship code without a test that demonstrably catches its absence. Does NOT trigger on bug fixes (use bug-fix-discipline) or refactors (use test-first-extract). Will ask 1-3 clarifying questions before writing any code; safe to delegate from /feature command.
sync
Multi-machine git-backed sync of local TDD Pro state via the `tdd-pro-sync` branch. Use when operators run claude-tdd-pro on more than one machine and want their FAILURE-LOG, decisions, audit checkpoints, workflow state, operator-curated URL registries, operator/community trees, and paywalled attestations to follow them between hosts.
strict-component-tests
Use when writing or reviewing test files. Enforces strict assertions that actually catch regressions (getByRole, exact counts, jest-dom matchers) in contrast to permissive tests (queryAllByText length > 0) that pass against broken UIs. References QUALITY-BAR.md for the canonical strictness rules.
spec
暂无简介
spec-first
Use when the user describes a non-trivial feature or system that should be specified in writing before any code is written. Pattern from Geoffrey Huntley's "Ralph" loop, OpenSpec, intent-driven.dev, and Kent Beck's "augmented coding" framing — specs+tests are the durable artifact, code is the disposable one. Produces a Markdown spec document that the user reviews; only after approval does any code get written (typically via tdd-feature-build or /feature).