Auto-Allow Bash Commands in Sandbox Mode#
What's wrong with this entry?
What: When sandboxing is enabled and you're in "accept edits" mode, safe bash commands now execute automatically without permission prompts.
How to use:
# Enable the sandbox with auto-allow feature
claude --configure
# Select "Sandbox BashTool, with auto-allow in accept edits mode"
# Now when you ask Claude to create files/directories, commands like
# mkdir, touch, mv, cp execute automatically when sandboxed
Details:
- Only activates when all conditions are met: sandbox enabled, auto-allow feature enabled, command is sandboxable, and user is in "acceptEdits" mode
- Safe commands like
mkdir,touch,rm,rmdir,mv,cp,sedare pre-approved in acceptEdits mode - User-defined deny/ask rules are still respected
- Commands can be excluded via
sandbox.excludedCommandsconfiguration - Falls back to standard permission prompting if conditions aren't met
- Evidence:
hL0()function at lines 206586-206604 andTN6()decision logic at line 206562 in pretty-v2.0.24.js