From 7435566498458b09c9fe2872abdb51fbdd071a5a Mon Sep 17 00:00:00 2001 From: asepharyana Date: Sat, 25 Jul 2026 11:58:44 +0700 Subject: [PATCH] fix(hub-guide): correct hooks.json format and remove redundant manifest field - hooks.json needs 'hooks' wrapper key at top level - Remove 'hooks' field from plugin.json (auto-discovered from hooks/hooks.json) - Simplify hook entries (no nested hooks array) --- .claude-plugin/plugin.json | 1 - hooks/hooks.json | 14 ++++++-------- 2 files changed, 6 insertions(+), 9 deletions(-) diff --git a/.claude-plugin/plugin.json b/.claude-plugin/plugin.json index e9ef4b9..9d1d969 100644 --- a/.claude-plugin/plugin.json +++ b/.claude-plugin/plugin.json @@ -6,6 +6,5 @@ "name": "Asep Haryana Saputra", "email": "asepharyana@users.noreply.github.com" }, - "hooks": "./hooks/hooks.json", "keywords": ["best-practice", "clean-code", "engineering-guide", "programming-standards", "architecture"] } diff --git a/hooks/hooks.json b/hooks/hooks.json index 987774e..abd960e 100644 --- a/hooks/hooks.json +++ b/hooks/hooks.json @@ -1,17 +1,15 @@ { - "SessionStart": [{ - "hooks": [{ + "hooks": { + "SessionStart": [{ "type": "command", "command": "bash \"$CLAUDE_PLUGIN_ROOT/hooks/scripts/detect-project.sh\"", "timeout": 10 - }] - }], - "PreToolUse": [{ - "matcher": "Write|Edit", - "hooks": [{ + }], + "PreToolUse": [{ + "matcher": "Write|Edit", "type": "command", "command": "bash \"$CLAUDE_PLUGIN_ROOT/hooks/scripts/detect-file-type.sh\" \"$TOOL_INPUT\"", "timeout": 10 }] - }] + } }