[BUG] /add-dir directories should inherit existing permission rules

Resolved 💬 2 comments Opened Mar 20, 2026 by toddthetrainnut Closed Mar 20, 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?

When using /add-dir to add an additional working directory, commands that access paths in that directory still prompt for permission — even when the user has broad allow rules like Bash(ls *) and Read in their settings.

What Should Happen?

The command should run without prompting, since:

  • Bash/Read/Glob/Grep is in the allow list
  • The directory was explicitly added via /add-dir

Error Messages/Logs

ls /c/Source/Server/MyProject/ | grep -i "SOMEFILE"
Run shell command

Do you want to proceed?
❯ 1. Yes
  2. Yes, allow reading from //c/EpicSource/TS2M/AnotherProject/M-routines/ from this project
  3. No

Steps to Reproduce

  1. Configure global settings (~/.claude/settings.json) with:

"permissions": {
"allow": ["Read", "Glob", "Grep", "Bash(ls *)"]
}

  1. Start Claude Code in a project directory (e.g., /c/Source/Client/MyProject)
  2. Use /add-dir /c/Source/Server/MyProject to add a second working directory
  3. Claude runs a Bash or Read command that reads from the added directory

Claude Model

Opus

Is this a regression?

I don't know

Last Working Version

_No response_

Claude Code Version

2.1.80

Platform

Anthropic API

Operating System

Windows

Terminal/Shell

PowerShell

Additional Information

_No response_

View original on GitHub ↗

This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗