fix(hooks): restore SessionStart + PreToolUse command hooks
Restore detect-project.sh, detect-file-type.sh, and hooks.json
from working version (80feaf2) with prompt-detection guidance lines.
This commit is contained in:
+12
-3
@@ -1,9 +1,18 @@
|
||||
{
|
||||
"hooks": {
|
||||
"Stop": [{
|
||||
"SessionStart": [{
|
||||
"hooks": [{
|
||||
"type": "prompt",
|
||||
"prompt": "--- skill detect ---\nRead the user's prompt. Detect what language, framework, tool, or topic they are asking about. If it matches any hub-guide skill concept (see available skills), activate that skill's rules for your response.\n\nDetection is concept-based, not keyword-based — works regardless of what language the user speaks.\n---"
|
||||
"type": "command",
|
||||
"command": "bash \"$CLAUDE_PLUGIN_ROOT/hooks/scripts/detect-project.sh\"",
|
||||
"timeout": 10
|
||||
}]
|
||||
}],
|
||||
"PreToolUse": [{
|
||||
"matcher": "Write|Edit",
|
||||
"hooks": [{
|
||||
"type": "command",
|
||||
"command": "bash \"$CLAUDE_PLUGIN_ROOT/hooks/scripts/detect-file-type.sh\" \"$TOOL_INPUT\"",
|
||||
"timeout": 10
|
||||
}]
|
||||
}]
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user