Auto mode writes to disk on ambiguous "give me an edited file" requests, even for files outside the active project
Title: Auto mode writes to disk on ambiguous "give me an edited file" requests, even for files outside the active project
Summary
When Auto mode (permission mode that biases toward acting without pausing for clarifying questions) is active, a request phrased as "give me an edited version of [file]" was interpreted as an instruction to write the change directly to disk, rather than as a request to draft the change for review. This happened for a file that was outside the git repository / project Claude Code was invoked in (a personal dotfile in the user's home directory), which raises the stakes of an unsolicited write more than an in-repo edit would.
Steps to reproduce
- Start a Claude Code session in a project directory (e.g. a git repo) with Auto mode enabled.
- Paste the contents of an unrelated config file that lives outside the project (e.g. a dotfile in
$HOME) and ask: "Can you take a look at this and give me an appropriate edited version?" - Observe that Claude edits the real file on disk directly, rather than presenting a draft/diff for review first.
Expected behavior
For files outside the current project scope, an ambiguous "give me an edited version" type request should default to producing a draft (shown inline, or written to a scratch/temp location) for the user to review — not a direct write to the real file — unless the user has explicitly asked Claude to apply/implement the change. Auto mode's "act without pausing" default seems to be overriding this distinction between in-project work (where direct edits are the expected workflow) and out-of-project system/personal files (where a direct unreviewed write is a bigger trust step).
Impact
Low severity in this instance (the edit was reasonable and reversible), but the same pattern could cause unwanted, hard-to-notice writes to other personal/system configuration files outside a project's scope, which is the kind of action that should generally get a lighter-touch confirmation step regardless of Auto mode.
Suggested fix
Treat "outside the active project/repo" as a signal that lowers the bar for pausing to confirm before writing to disk, even under Auto mode — independent of whether the request phrasing sounds like a direct edit instruction.