From 80feaf2f16f1168d6932d7557643bad28139d2d3 Mon Sep 17 00:00:00 2001 From: asepharyana Date: Sat, 25 Jul 2026 11:59:34 +0700 Subject: [PATCH] fix(hub-guide): add nested hooks array in hooks.json entries Each event entry needs hooks: [{ type, command, timeout }] inside it. --- hooks/hooks.json | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/hooks/hooks.json b/hooks/hooks.json index abd960e..d40bde1 100644 --- a/hooks/hooks.json +++ b/hooks/hooks.json @@ -1,15 +1,19 @@ { "hooks": { "SessionStart": [{ - "type": "command", - "command": "bash \"$CLAUDE_PLUGIN_ROOT/hooks/scripts/detect-project.sh\"", - "timeout": 10 + "hooks": [{ + "type": "command", + "command": "bash \"$CLAUDE_PLUGIN_ROOT/hooks/scripts/detect-project.sh\"", + "timeout": 10 + }] }], "PreToolUse": [{ "matcher": "Write|Edit", - "type": "command", - "command": "bash \"$CLAUDE_PLUGIN_ROOT/hooks/scripts/detect-file-type.sh\" \"$TOOL_INPUT\"", - "timeout": 10 + "hooks": [{ + "type": "command", + "command": "bash \"$CLAUDE_PLUGIN_ROOT/hooks/scripts/detect-file-type.sh\" \"$TOOL_INPUT\"", + "timeout": 10 + }] }] } }