Plugin marketplace sync drops execute permissions on .sh files
Resolved 💬 4 comments Opened Mar 27, 2026 by klueless-io Closed Apr 18, 2026
Summary
Every time a Claude Code session starts, the plugin marketplace sync copies .sh files into ~/.claude/plugins/marketplaces/ but drops the Unix execute bit — files end up 644 instead of 755. This causes hook scripts to fail with "Permission denied".
Reproduction
- Install any plugin with shell hook scripts (e.g.
ralph-loopwith a stop hook) - Run
chmod +xon the.shfiles in~/.claude/plugins/marketplaces/.../hooks/ - Start a new Claude Code session
- Observe all
.shfiles are now644again (execute bit stripped) - Hook fails:
/bin/sh: .../stop-hook.sh: Permission denied
Details
- Affected path:
~/.claude/plugins/marketplaces/<marketplace>/plugins/<plugin>/— all.shfiles - Cache version: The SHA-versioned cache entries in
~/.claude/plugins/cache/sometimes retain755, but the marketplace working copy does not - Scope: Not limited to one plugin — observed across ralph-loop, plugin-dev, learning-output-style, math-olympiad, explanatory-output-style, and others (17 scripts total)
- Timestamps: All affected files share the same timestamp matching session start, confirming the sync is the cause
- Workaround:
find ~/.claude/plugins/marketplaces -name "*.sh" -exec chmod +x {} +after each session start
Expected behaviour
The marketplace sync should preserve Unix file mode bits (specifically the execute bit) when copying scripts from cache to the marketplaces directory.
Environment
- macOS (Darwin 25.3.0, Apple Silicon)
- Claude Code v2.1.83+
- First observed ~2026-03-26, confirmed reproducible across sessions
This issue has 4 comments on GitHub. Read the full discussion on GitHub ↗