Windows: Hook relative paths with `..` intermittently fail to resolve
Resolved 💬 2 comments Opened Apr 1, 2026 by colton-skimmer Closed Apr 3, 2026
Description
On Windows, hooks configured in .claude/settings.json with relative paths containing .. intermittently fail to resolve. The .. appears to be dropped or not resolved, causing the path to treat the target as a subdirectory instead of a sibling.
Reproduction
Settings.json hook config:
{
"Stop": [{
"hooks": [{
"type": "command",
"command": "node \"../skimmer-ai-orchestration/.claude/scripts/hooks.mjs\" session-end",
"timeout": 30000,
"continueOnError": true
}]
}]
}
Expected path resolution (CWD = C:\src\skimmer\skimmer-eng-automation):
C:\src\skimmer\skimmer-ai-orchestration\.claude\scripts\hooks.mjs
Actual path in error:
C:\src\skimmer\skimmer-eng-automation\skimmer-ai-orchestration\.claude\scripts\hooks.mjs
The .. is not resolved — the sibling repo path is treated as a subdirectory.
Notes
- Running the same command from bash in the same CWD resolves correctly
- Happens intermittently (not every time)
- Affects Stop, PreToolUse (Write/Edit), and PostToolUse hooks — all configured with the same relative path pattern
continueOnError: truemakes it non-blocking but the error output is visible- Quoting the path (added in our project setup) did not fully resolve the issue
Environment
- Windows 11 Home 10.0.26200
- Claude Code CLI (latest)
- Node.js (latest LTS)
- Shell: bash (Git Bash on Windows)
This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗