CLAUDE.md in --add-dir folders is silently skipped, including when Claude edits files in that folder
In a multi-folder VSCode workspace, secondary folders become --add-dir directories. Per the docs, their CLAUDE.md files are not loaded unless CLAUDE_CODE_ADDITIONAL_DIRECTORIES_CLAUDE_MD=1 is set.
Three problems with that default:
1. No signal. I asked Claude to edit a file in a secondary folder. A CLAUDE.md sat in that same folder with mandatory editing rules (all edits must be written as CriticMarkup suggestions, never in-place rewrites). Claude read the target file, edited it, and never knew the rules existed. Nothing warned either of us — I only found out because I knew the file was there and asked why it had been ignored.
2. Inconsistent with subdirectory behaviour. CLAUDE.md files in subdirectories load on demand when Claude reads files in them. Applying the same rule to --add-dir folders would match that model: load it when Claude actually touches a file in that folder.
3. The opt-out is invisible in the IDE. I never typed --add-dir. The VSCode extension turned my multi-folder workspace into those entries, so a flag-scoped default silently applied to a flag I didn't know was in play. From the user's side, a CLAUDE.md sitting next to the file being edited simply does nothing, with no way to discover why.
Suggested fix
Either:
- load
--add-dirCLAUDE.md on demand, the same way subdirectory CLAUDE.md files load, or - surface a one-line notice when Claude reads or edits a file in a folder whose CLAUDE.md was skipped.
Environment
- Claude Code in the VSCode extension, multi-folder workspace
- Windows 11
- Docs describing current behaviour: https://code.claude.com/docs/en/memory (see "Load from additional directories")
This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗