diff --git a/zh/06-hooks/README.md b/zh/06-hooks/README.md index 2a4115d..f7b3342 100644 --- a/zh/06-hooks/README.md +++ b/zh/06-hooks/README.md @@ -42,14 +42,28 @@ chmod +x ~/.claude/hooks/*.sh ```json { "hooks": { - "PreToolUse": [{ - "matcher": "Write", - "hooks": ["~/.claude/hooks/format-code.sh"] - }], - "PostToolUse": [{ - "matcher": "Write", - "hooks": ["~/.claude/hooks/security-scan.sh"] - }] + "PreToolUse": [ + { + "matcher": "Write", + "hooks": [ + { + "type": "command", + "command": "~/.claude/hooks/format-code.sh" + } + ] + } + ], + "PostToolUse": [ + { + "matcher": "Write", + "hooks": [ + { + "type": "command", + "command": "~/.claude/hooks/security-scan.sh" + } + ] + } + ] } } ```