Files
claude-mem/plugin/hooks/hooks.json
T
Alex Newman f41824fa59 fix: quote all CLAUDE_PLUGIN_ROOT paths in hooks.json for Windows usernames with spaces
Wraps all ${CLAUDE_PLUGIN_ROOT} variable expansions with quotes to handle
Windows paths containing spaces (e.g., C:\Users\John Doe\.claude\...).

Without quotes, the shell splits the path at spaces, causing Node.js to
interpret the first segment as JavaScript and throw SyntaxError: Unexpected
token ':'.

This fix updates the Bun migration (v7.1.0) to include proper quoting,
superseding PR #212 which was based on pre-migration code.

Fixes #212

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-12 22:28:19 -05:00

68 lines
1.5 KiB
JSON

{
"description": "Claude-mem memory system hooks",
"hooks": {
"SessionStart": [
{
"matcher": "startup|clear|compact",
"hooks": [
{
"type": "command",
"command": "bun \"${CLAUDE_PLUGIN_ROOT}/scripts/smart-install.js\" && bun \"${CLAUDE_PLUGIN_ROOT}/scripts/context-hook.js\"",
"timeout": 300
},
{
"type": "command",
"command": "bun \"${CLAUDE_PLUGIN_ROOT}/scripts/user-message-hook.js\"",
"timeout": 10
}
]
}
],
"UserPromptSubmit": [
{
"hooks": [
{
"type": "command",
"command": "bun \"${CLAUDE_PLUGIN_ROOT}/scripts/new-hook.js\"",
"timeout": 120
}
]
}
],
"PostToolUse": [
{
"matcher": "*",
"hooks": [
{
"type": "command",
"command": "bun \"${CLAUDE_PLUGIN_ROOT}/scripts/save-hook.js\"",
"timeout": 120
}
]
}
],
"Stop": [
{
"hooks": [
{
"type": "command",
"command": "bun \"${CLAUDE_PLUGIN_ROOT}/scripts/summary-hook.js\"",
"timeout": 120
}
]
}
],
"SessionEnd": [
{
"hooks": [
{
"type": "command",
"command": "bun \"${CLAUDE_PLUGIN_ROOT}/scripts/cleanup-hook.js\"",
"timeout": 120
}
]
}
]
}
}