fix(tools): add bare git command patterns to allowedTools
Git commands without arguments (git push, git status, git diff, etc.) were not matched by the existing wildcard patterns. Added bare variants and git stash support. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -60,16 +60,24 @@ ALLOWED_TOOLS = [
|
||||
"Bash(.venv/bin/python3 *)",
|
||||
"Bash(pip *)",
|
||||
"Bash(pytest *)",
|
||||
# Git
|
||||
# Git — both bare commands and commands with arguments
|
||||
"Bash(git add *)",
|
||||
"Bash(git commit *)",
|
||||
"Bash(git push)",
|
||||
"Bash(git push *)",
|
||||
"Bash(git pull)",
|
||||
"Bash(git pull *)",
|
||||
"Bash(git status)",
|
||||
"Bash(git status *)",
|
||||
"Bash(git diff)",
|
||||
"Bash(git diff *)",
|
||||
"Bash(git log)",
|
||||
"Bash(git log *)",
|
||||
"Bash(git checkout *)",
|
||||
"Bash(git branch)",
|
||||
"Bash(git branch *)",
|
||||
"Bash(git stash)",
|
||||
"Bash(git stash *)",
|
||||
# Node/npm
|
||||
"Bash(npm *)",
|
||||
"Bash(node *)",
|
||||
|
||||
Reference in New Issue
Block a user