[BUG] Bash command executed without asking for permission
Resolved 💬 3 comments Opened Jan 9, 2026 by joypeterson Closed Feb 23, 2026
Preflight Checklist
- [x] I have searched existing issues and this hasn't been reported yet
- [x] This is a single bug report (please file separate reports for different bugs)
- [x] I am using the latest version of Claude Code
What's Wrong?
Background
I asked Claude Code to generate a commit message for the changes that have been made and commit the changes. Claude commits the changes using Bash(git commit -m ...). I always want to preview the commit message before allowing the commit to occur so I have not allowed Bash(git commit:*) or Bash(git:*) in either my project settings or user settings files. This has been working until now.
What Should Happen?
Claude Code should have asked for permission to commit the changes because it had not been granted permission to execute git commit commands.
Error Messages/Logs
Steps to Reproduce
- Ensure that Claude Code does not have permission to execute
git commitcommands in either the project settings or user settings files. - Make some code changes
- Ask Claude Code to generate a commit message and commit the changes.
Claude Model
Opus
Is this a regression?
Yes, this worked in a previous version
Last Working Version
1.76.x
Claude Code Version
2.1.2
Platform
Anthropic API
Operating System
macOS
Terminal/Shell
Other - Antigravity
Additional Information
_No response_
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗