diff options
| author | Morgan Lunt <morganl@anthropic.com> | 2026-09-23 19:20:24 -0700 |
|---|---|---|
| committer | Morgan Lunt <morganl@anthropic.com> | 2026-09-24 17:50:20 -0700 |
| commit | 9b4e3c21f27766422e43259da71745b863684784 (patch) | |
| tree | f2f31eeb685997f58fe9022f2607240a683117a6 /plugins/code-modernization/README.md | |
| parent | cbba09effc7046cf649b78dc4b84e95cf1a64edd (diff) | |
code-modernization: preflight checks that legacy/ is protected from edits
The commands are written never to edit legacy/, but nothing checked
that anything enforced it. Preflight now has a Check 7 that reads,
without changing anything, the project's .claude/settings.json and
.claude/settings.local.json and the user's settings file, and looks for
an Edit deny rule that covers legacy/. The result is a row in
PREFLIGHT.md with the same status marks as the other checks: a green row
names the file and the rule, and a warning prints the settings snippet
to add. The check never edits a settings file and never suggests
loosening one.
The check also says plainly that a permission rule covers the file tools
and the shell commands the CLI recognizes, not a script that
opens the files itself, so a green row is not a guarantee. A read-only
mount, or a sandbox that blocks writes to legacy/, is. The README no
longer says the settings file enforces the invariant: the commands keep
to it by convention and the rule backs that up.
Diffstat (limited to 'plugins/code-modernization/README.md')
| -rw-r--r-- | plugins/code-modernization/README.md | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/plugins/code-modernization/README.md b/plugins/code-modernization/README.md index 051aa51f..667ba809 100644 --- a/plugins/code-modernization/README.md +++ b/plugins/code-modernization/README.md @@ -85,7 +85,7 @@ Specialist subagents invoked by the commands (or directly): ## Recommended workspace setup -A `.claude/settings.json` in the project you're modernizing enforces the core invariant — never touch `legacy/`, freely edit `analysis/` and `modernized/`: +The commands never edit `legacy/`, by convention. A `.claude/settings.json` in the project you're modernizing backs that up with a deny rule for `legacy/` and allow rules for `analysis/` and `modernized/`; `/code-modernization:modernize-preflight` checks for the deny rule: ```json { |
