Bug
On Windows, the getProjectId() function in all three hook files uses cwd.split('/').pop() which doesn't work because Windows uses backslash (\) as path separator.
Affected files:
hooks/claude/session-start.ts
hooks/claude/user-prompt.ts
hooks/claude/curation.ts
Current code:
function getProjectId(cwd: string): string {
return cwd.split('/').pop() || 'default'
}
Example: When cwd is E:\Code\claude-toolkit, split('/') returns ['E:\Code\claude-toolkit'] — the entire path as one element. So pop() returns the full path instead of just claude-toolkit.
Fix: Use path.basename() which handles both / and \:
function getProjectId(cwd: string): string {
return require('path').basename(cwd) || 'default'
}
Impact: Memory hooks silently send wrong project IDs on Windows, so memories are never stored/retrieved correctly. The memory server shows 0 memories for projects even after multiple sessions.
Bug
On Windows, the
getProjectId()function in all three hook files usescwd.split('/').pop()which doesn't work because Windows uses backslash (\) as path separator.Affected files:
hooks/claude/session-start.tshooks/claude/user-prompt.tshooks/claude/curation.tsCurrent code:
Example: When
cwdisE:\Code\claude-toolkit,split('/')returns['E:\Code\claude-toolkit']— the entire path as one element. Sopop()returns the full path instead of justclaude-toolkit.Fix: Use
path.basename()which handles both/and\:Impact: Memory hooks silently send wrong project IDs on Windows, so memories are never stored/retrieved correctly. The memory server shows 0 memories for projects even after multiple sessions.