Skip to content

Commit 9cf8b2b

Browse files
cahaselerclaude
andcommitted
fix: wrap hooks.json in required plugin format
Plugin hooks.json requires a wrapper object with "hooks" property. The previous format was for settings.json, not plugin hooks. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
1 parent 060fc1f commit 9cf8b2b

File tree

1 file changed

+43
-40
lines changed

1 file changed

+43
-40
lines changed

hooks/hooks.json

Lines changed: 43 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -1,42 +1,45 @@
11
{
2-
"PostToolUse": [
3-
{
4-
"name": "edit-validation",
5-
"script": "bun run ${CLAUDE_PLUGIN_ROOT}/hooks/edit-validation.ts",
6-
"description": "Validates TypeScript and Biome compliance after file edits"
7-
}
8-
],
9-
"PreToolUse": [
10-
{
11-
"name": "pre-tool-validation",
12-
"script": "bun run ${CLAUDE_PLUGIN_ROOT}/hooks/pre-tool-validation.ts",
13-
"description": "Validates branch protection and task file integrity before tool use"
14-
},
15-
{
16-
"name": "powershell-guidance",
17-
"script": "bun run ${CLAUDE_PLUGIN_ROOT}/hooks/powershell-guidance.ts",
18-
"description": "Windows only: Converts Linux commands to PowerShell or provides guidance"
19-
}
20-
],
21-
"UserPromptSubmit": [
22-
{
23-
"name": "autoflow-control",
24-
"script": "bun run ${CLAUDE_PLUGIN_ROOT}/hooks/user-message.ts",
25-
"description": "Detects autoflow mode activation and deactivation"
26-
}
27-
],
28-
"PermissionRequest": [
29-
{
30-
"name": "autoflow-permissions",
31-
"script": "bun run ${CLAUDE_PLUGIN_ROOT}/hooks/permission-request.ts",
32-
"description": "Denies permissions in autoflow mode with helpful message"
33-
}
34-
],
35-
"Stop": [
36-
{
37-
"name": "autoflow-evaluator",
38-
"script": "bun run ${CLAUDE_PLUGIN_ROOT}/hooks/stop.ts",
39-
"description": "Evaluates if Claude should continue working in autoflow mode"
40-
}
41-
]
2+
"description": "cc-track validation and autoflow hooks",
3+
"hooks": {
4+
"PostToolUse": [
5+
{
6+
"name": "edit-validation",
7+
"script": "bun run ${CLAUDE_PLUGIN_ROOT}/hooks/edit-validation.ts",
8+
"description": "Validates TypeScript and Biome compliance after file edits"
9+
}
10+
],
11+
"PreToolUse": [
12+
{
13+
"name": "pre-tool-validation",
14+
"script": "bun run ${CLAUDE_PLUGIN_ROOT}/hooks/pre-tool-validation.ts",
15+
"description": "Validates branch protection and task file integrity before tool use"
16+
},
17+
{
18+
"name": "powershell-guidance",
19+
"script": "bun run ${CLAUDE_PLUGIN_ROOT}/hooks/powershell-guidance.ts",
20+
"description": "Windows only: Converts Linux commands to PowerShell or provides guidance"
21+
}
22+
],
23+
"UserPromptSubmit": [
24+
{
25+
"name": "autoflow-control",
26+
"script": "bun run ${CLAUDE_PLUGIN_ROOT}/hooks/user-message.ts",
27+
"description": "Detects autoflow mode activation and deactivation"
28+
}
29+
],
30+
"PermissionRequest": [
31+
{
32+
"name": "autoflow-permissions",
33+
"script": "bun run ${CLAUDE_PLUGIN_ROOT}/hooks/permission-request.ts",
34+
"description": "Denies permissions in autoflow mode with helpful message"
35+
}
36+
],
37+
"Stop": [
38+
{
39+
"name": "autoflow-evaluator",
40+
"script": "bun run ${CLAUDE_PLUGIN_ROOT}/hooks/stop.ts",
41+
"description": "Evaluates if Claude should continue working in autoflow mode"
42+
}
43+
]
44+
}
4245
}

0 commit comments

Comments
 (0)