I'm trying to find a way to configure Claude Code so that it automatically responds 'yes' to every prompt without me needing to press enter repeatedly. My previous attempt was impressive, but I still had to click through about 20 times for it to complete a PR. I want it to run fully autonomously, so any tips on how to achieve that would be great!
3 Answers
Just a heads up, saying 'yes' to everything might lead to problems. Sometimes, Claude can make mistakes, like altering a crucial class instead of a smaller one that actually needs the change. I’ve had a few sessions where it caused some major issues because of that. So, be cautious!
When you allow 'yes', make sure to check the options because there’s one that says 'Yes, and don’t ask me again for similar things.' Just remember, this could lead to some wrong choices. You might still need to confirm a few things if the actions differ, like between updating a file or running a test, so keep an eye out for that.
You can use a command like `claude --print "[prompt]" --dangerously-skip-permissions --verbose --output-format stream-json | jq`. I'm currently working on a self-hosted webhook that launches a Docker container to run Claude in unattended mode. It gets triggered from a GitHub comment, similar to the integration they recently released, but I have some tweaks in mind to make it even more functional.
That’s cool, thanks for sharing!
Agreed! It’s risky to hand everything over to Claude without oversight.