I'm dealing with the autorun prompt in Claude Code whenever it tries to execute bash commands, and I want to balance convenience with caution. I know the options are to say 'Yes,' 'Yes and don't ask again,' or 'No,' but I'm concerned about risky commands. For basic commands like 'mkdir,' it's easy to say not to ask again, but how about those more complex or potentially risky commands? Is there a way to make Claude Code check against a list of pre-approved bash commands to avoid unnecessary prompts?
2 Answers
After you've set the permissions for your current project, you can head over to the `.claude/settings.json` file. From there, just review the settings and copy them to your `~/ .claude` directory for reuse. This way, you won’t have to keep re-allowing permissions each time you start a new project.
You can actually use the command `claude --dangerously-skip-permissions`, but I get your point. That might seem like giving Claude too much power, right? You could look into managing permissions more selectively instead of skipping all of them at once.
Thanks for the tip! I just want to avoid any potential mishaps, so maybe I’ll stick with more selective settings.