Description
The SessionStart hooks write env vars to $CLAUDE_ENV_FILE without quoting their
values. When the world path contains a space (common on macOS iCloud/Obsidian:
~/Library/Mobile Documents/iCloud~md~obsidian/...), this breaks every Bash tool call.
Affected lines:
hooks/scripts/alive-session-new.sh (~lines 132-135): ALIVE_SESSION_ID, ALIVE_WORLD_ROOT, ALIVE_PLUGIN_ROOT
hooks/scripts/alive-session-resume.sh (~line 31): ALIVE_WORLD_ROOT
Example:
echo "ALIVE_WORLD_ROOT=$WORLD_ROOT" >> "$CLAUDE_ENV_FILE"
Claude Code splices these lines into each tool command as shell. zsh parses
ALIVE_WORLD_ROOT=/Users/.../Library/Mobile as an env-assignment prefix and then
tries to execute Documents/iCloud~md~obsidian/Documents/AliveWorld as a command,
producing on EVERY Bash call:
zsh:2: no such file or directory: Documents/iCloud~md~obsidian/Documents/AliveWorld
Cosmetic (the actual command still runs), but it prepends noise to every command's
output, which is very disruptive in an interactive session.
Expected Behaviour
No spurious error. The env var should be set to the full path and commands should
run with clean output, regardless of spaces in the world path.
Fix: quote the values, e.g.
echo "ALIVE_WORLD_ROOT="$WORLD_ROOT"" >> "$CLAUDE_ENV_FILE"
(same for ALIVE_SESSION_ID and ALIVE_PLUGIN_ROOT).
System
- Plugin: 3.2.0
- Engine: claude-opus-4-8
- OS: Darwin
- Context: ~82%
Sent via /alive:feedback
Description
The SessionStart hooks write env vars to
$CLAUDE_ENV_FILEwithout quoting theirvalues. When the world path contains a space (common on macOS iCloud/Obsidian:
~/Library/Mobile Documents/iCloud~md~obsidian/...), this breaks every Bash tool call.Affected lines:
hooks/scripts/alive-session-new.sh(~lines 132-135): ALIVE_SESSION_ID, ALIVE_WORLD_ROOT, ALIVE_PLUGIN_ROOThooks/scripts/alive-session-resume.sh(~line 31): ALIVE_WORLD_ROOTExample:
echo "ALIVE_WORLD_ROOT=$WORLD_ROOT" >> "$CLAUDE_ENV_FILE"
Claude Code splices these lines into each tool command as shell. zsh parses
ALIVE_WORLD_ROOT=/Users/.../Library/Mobileas an env-assignment prefix and thentries to execute
Documents/iCloud~md~obsidian/Documents/AliveWorldas a command,producing on EVERY Bash call:
Cosmetic (the actual command still runs), but it prepends noise to every command's
output, which is very disruptive in an interactive session.
Expected Behaviour
No spurious error. The env var should be set to the full path and commands should
run with clean output, regardless of spaces in the world path.
Fix: quote the values, e.g.
echo "ALIVE_WORLD_ROOT="$WORLD_ROOT"" >> "$CLAUDE_ENV_FILE"
(same for ALIVE_SESSION_ID and ALIVE_PLUGIN_ROOT).
System
Sent via /alive:feedback