Repository navigation
feat(docs-naming): read per-person config from a file_names userConfig option #18067
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
melodic-automation-lanes
wants to merge
2
commits into
main
Choose a base branch
from
work-resolve-issue/issue-18002-44954440976-1
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+757
−160
Open
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
13 changes: 13 additions & 0 deletions
13
.changes/docs-naming/work-resolve-issue-issue-18002-44954440976-1-c691b314.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,13 @@ | ||
| --- | ||
| bump: minor | ||
| --- | ||
|
|
||
| ### Added | ||
|
|
||
| - **A `file_names` `userConfig` option is the per-person layer** ([#18002](https://github.com/melodic-software/claude-code-plugins/issues/18002)). It holds your own `file_names` keys as one JSON object and takes the place of the user-global `~/.claude/docs-naming.json`, per the config-cascade layers. It merges where that file did: under the team and personal override files, adding to the policy-floor keys and ignored for `generated`. A value that is not one JSON object is reported and ignored, and one holding a whole old file (`{"schema": 1, "file_names": {...}}`) is read as its `file_names` object. Every skill passes the option to its scripts through a new `--user-config` flag, and `scripts/resolve-config.sh` also reads `CLAUDE_PLUGIN_OPTION_FILE_NAMES`. | ||
| - **`setup-apply.sh --user-config-value`** previews copying the old user files' keys into the option: per file, the keys it would add, then the merged value and a `values.json` for `claude plugin configure`. It writes nothing. `/docs-naming:setup apply` shows the preview, and on a yes gives the native command that saves it, leaving the old file in place. | ||
|
|
||
| ### Changed | ||
|
|
||
| - **`~/.claude/docs-naming.json` and `~/.claude/docs-hygiene.json` are read only while the option is unset or invalid**, the first that exists, in the option's place. Each `resolve` run that finds either file prints one warning naming each file and the option. With a valid option set, neither file is read. A later change removes the read. | ||
| - **The resolver names the per-person layer `userConfig`** in `layers` provenance and in each tier's `_layer`, where it said `user-global`. `paths` prints a `userConfig file_names` row (`present`, `absent` or `invalid`), then one row per old user file (`legacy` when read, `legacy-unread` when not). `/docs-naming:setup check` shows a `layer userConfig` row and an `old user file` WARN row per file. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
manifest userConfig.file_names: flag, added free-form
stringoption with nooptionslist (not a selector, not inert). Skill text substitutes${user_config.file_names}into single-quoted Bash arguments for setup-check.sh, setup-apply.sh, inventory.sh, sweep.sh, emit-gate.sh and apply-rename.sh, and resolve-config.sh reads itWhat installed users get on update: a new per-person config layer. The default
""is unset, so nothing changes until a user sets the option. Once it is set, the value joins thefile_namesmerge between the bundled defaults and the team layer.What bounds it:
generatedregenerator command (resolve-config.shL345-357)._layer: userConfig, andsweep.shL156 treats that layer as non-authoritative, so they cannot override a team tier.jqon stdin and neverevalit.Remaining exposure: when the agent builds the Bash command, keeping the value inside one single-quoted argument depends on the model following the skill's "escape any single quote in it" instruction. A value that contains
'and is pasted without escaping would break out of the argument. The value comes from the operator's own user settings, so only the operator can hurt themselves this way, not a third party. If you want this to rely on code rather than the model, pass the value on stdin or in a file instead of in the command line.severity: IMPORTANT
claude-lane: claude-security-review
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pr-unblock / address-feedback: UNCERTAIN, left open
Evidence:
plugins/docs-naming/.claude-plugin/plugin.json:29,plugins/docs-naming/skills/setup/SKILL.md:31,plugins/docs-naming/scripts/resolve-config.sh:345