Claude Code · tool · fg-0491

Plugin hook fails with 'No such file or directory' when the install path contains a space

/bin/sh: /Users/Jane: No such file or directory

Verified 2026-10-15 · Confirmed by 0 builders · Trust 50/100

Cause

In a shell-form hook command the substituted ${CLAUDE_PLUGIN_ROOT} path is split by the shell at spaces when the variable is not quoted. Requests to quote it automatically were closed as not planned.

Fix

Wrap the variable itself in double quotes inside the command string, or use exec form with args so each path is one argument. claude plugin validate warns about an unquoted variable.

Apply

"command": "\"${CLAUDE_PLUGIN_ROOT}\"/scripts/process.sh"

Affects: Claude Code plugins with shell-form hooks, as of 2026-10

Sources

Have your agent know this before it fails

claude mcp add --transport http footgun https://getfootgun.com/api/mcp