[DOCS] Protected directories in `acceptEdits` mode not documented — `.husky` addition undiscoverable
Documentation Type
Missing documentation (feature not documented)
Documentation Location
https://code.claude.com/docs/en/permission-modes
Section/Topic
The "Skip all checks with bypassPermissions mode" section documents protected directories for bypassPermissions, but the acceptEdits mode section ("Available modes" table and the mode comparison table) contains no mention that acceptEdits also has protected directories. The concept of protected directories in acceptEdits mode is entirely absent from the documentation.
Current Documentation
From permission-modes.md, the acceptEdits row in the available modes table:
| acceptEdits | Read and edit files | Iterating on code you're reviewing |
The bypassPermissions section (the only place protected directories are discussed) states:
bypassPermissionsmode disables permission prompts and safety checks. Tool calls execute immediately, except for writes to.git,.vscode, and.idea, which still prompt to prevent accidental corruption of repository state and local configuration.
From permissions.md, the mode table row for acceptEdits:
| acceptEdits | Automatically accepts file edit permissions for the session |
No documentation currently exists describing protected directories in acceptEdits mode, nor listing which directories are protected under it.
What's Wrong or Missing?
acceptEdits mode has a concept of protected directories — directories that still prompt for confirmation even when the mode would otherwise auto-accept file edits. As of v2.1.90, .husky was added to this list. However:
- The docs do not mention that
acceptEditsmode has any protected directories at all. - There is no list of which directories are protected under
acceptEdits(comparable to the list provided forbypassPermissions). - Users relying on
acceptEditsfor faster iteration have no way to know that writes to certain directories (such as.husky, which contains Git hooks) will still trigger a prompt.
This is particularly confusing because bypassPermissions protected directories are documented, creating an asymmetry: users reading about acceptEdits get no equivalent information.
Suggested Improvement
Add a section or note to the acceptEdits mode description — on both permission-modes.md and permissions.md — that:
- States that
acceptEditsauto-accepts file edits except for writes to certain protected directories. - Lists the protected directories (e.g.,
.git,.claude,.husky, and any others that apply). - Explains the rationale (preventing accidental corruption of repository state, Git hook configuration, etc.).
Example addition to the permission-modes.md bypassPermissions section prose, mirrored for acceptEdits:
Protected directories: writes to.git,.claude, and.huskystill prompt for confirmation to prevent accidental corruption of repository state and Git hook configuration.
The permissions.md mode table row for acceptEdits should also be updated from:
Automatically accepts file edit permissions for the session
to something like:
Automatically accepts file edit permissions for the session, except writes to protected directories (.git,.claude,.husky) which still prompt
Impact
Medium - Affects how users understand and use the product
Additional Context
Affected Pages:
| Page | Context |
|------|---------|
| https://code.claude.com/docs/en/permission-modes | Primary mode reference — acceptEdits mode description and the bypassPermissions protected-directory pattern to follow |
| https://code.claude.com/docs/en/permissions | Mode table row for acceptEdits needs updating |
Total scope: 2 pages affected
Source: Changelog v2.1.90
"Added .husky to protected directories (acceptEdits mode)"This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗