Global permission rules not matching paths under ~/Code/ and Bash commands
Description:
Global permission rules in ~/.claude/settings.json are not being applied correctly. Commands that should be auto-approved based
on configured rules are still prompting for confirmation.
Environment:
- OS: macOS (Darwin 25.2.0)
- Claude Code version: 2.0.61
Steps to Reproduce:
- Configure
~/.claude/settings.jsonwith these permissions:
``json``
{
"permissions": {
"allow": [
"Write(~/Code/**)",
"Write(.claude/**)",
"Bash(mkdir:*)",
"Bash(touch:*)"
]
}
}
- Navigate to a project under
~/Code/, e.g.,~/Code/browsery/
- Ask Claude Code to create a todo file at
.claude/todo.md
Expected Behavior:
The following operations should proceed without prompting:
Write(.claude/todo.md)— matchesWrite(.claude/**)mkdir -p ~/Code/browsery/.claude— matchesBash(mkdir:*)touch ~/Code/browsery/.claude/todo.md— matchesBash(touch:*)
Additionally, ~/Code/browsery/.claude/todo.md should match Write(~/Code/**).
Actual Behavior:
All three operations prompt for user confirmation:
````
Bash command
mkdir -p /Users/username/Code/browsery/.claude
Do you want to proceed?
````
Bash command
touch /Users/username/Code/browsery/.claude/todo.md
Do you want to proceed?
Additional Context:
- The
.claude/directory already existed whenmkdir -pwas attempted - The full absolute path
/Users/username/Code/browsery/.claude/todo.mdshould match the glob pattern~/Code/** - Unclear if this is a tilde expansion issue, glob matching issue, or both
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗