Bundled ripgrep binary ships without execute permissions on macOS ARM

Resolved 💬 2 comments Opened Apr 1, 2026 by majoma7 Closed Apr 18, 2026

Bug Description

The bundled ripgrep binary at vendor/ripgrep/arm64-darwin/rg ships with 644 permissions (no execute bit) when installed via Homebrew on macOS ARM (Apple Silicon). This causes silent failures in .claude/commands/ discovery — legacy commands are never loaded.

Impact

Any skills/commands defined as flat .md files in .claude/commands/ are not loaded by the CLI. Only the newer .claude/skills/ format (which uses fs.readdir instead of ripgrep) works. The VS Code extension UI is unaffected because it uses VS Code's own bundled ripgrep.

Steps to Reproduce

  1. Install Claude Code via npm on macOS ARM: npm install -g @anthropic-ai/claude-code
  2. Place .md skill files in <project>/.claude/commands/
  3. Run claude from terminal
  4. Observe that commands from .claude/commands/ are missing (only .claude/skills/ commands load)

Debug Evidence

claude -d --debug-file /tmp/debug.log -p "hi" --max-turns 0

Debug log shows:

Ripgrep first use test: FAILED (mode=builtin, path=.../vendor/ripgrep/arm64-darwin/rg)
Loaded 5 unique skills (5 unconditional, 0 conditional, managed: 0, user: 0, project: 5, additional: 0, legacy commands: 0)

File permissions:

$ stat -f "%Sp" .../vendor/ripgrep/arm64-darwin/rg
-rw-r--r--

Fix

chmod +x /opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/vendor/ripgrep/arm64-darwin/rg

After fix:

Ripgrep first use test: PASSED (mode=builtin, path=.../vendor/ripgrep/arm64-darwin/rg)
Loaded 30 unique skills (30 unconditional, 0 conditional, managed: 0, user: 0, project: 5, additional: 0, legacy commands: 25)

Suggested Permanent Fix

Ensure the ripgrep binary has execute permissions set in the npm package tarball, or add a postinstall script that sets chmod +x on the vendor binaries.

Environment

  • Claude Code version: 2.1.89
  • OS: macOS 15 (Darwin 25.2.0), Apple Silicon (ARM64)
  • Install method: Homebrew (npm install -g @anthropic-ai/claude-code)
  • Node: via Homebrew

View original on GitHub ↗

This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗