fix(cli,skill): unify config source, write SKILL.md, fix TS param parser#92
Merged
Conversation
Fixes three independent bugs: - fix(cli): server subcommands (list/info/validate) now read from ~/.claude/mcp.json instead of Claude Desktop config. Removes ServerManager; all paths go through common::load_mcp_config_from(). list_mcp_servers() returns empty vec (not error) when the file is absent. Fixes misleading error hint. Closes #81. - fix(skill): skill CLI now writes SKILL.md directly instead of dumping a JSON context blob to stdout. Output is rendered via a new skill-md.hbs Handlebars template and written atomically (temp + rename). Frontmatter values are YAML-quoted to prevent injection. Closes #82. - fix(skill): TypeScript property parser no longer extracts tokens from JSDoc comment lines as parameter names. parse_parameters() now iterates lines, skips comment-prefix lines, and strips inline // and /* */ comments before applying the anchored PROP_LINE_REGEX. The comment search is bounded at the first string-literal delimiter to avoid false truncation on URL types. Closes #83. BREAKING: skill command stdout shape changed from a raw GenerateSkillResult JSON dump to a SkillWriteResult object (success, output_path, bytes_written, tool_count).
8efc7ef to
60df188
Compare
This was
linked to
issues
May 3, 2026
Closed
Codecov Report❌ Patch coverage is @@ Coverage Diff @@
## master #92 +/- ##
==========================================
+ Coverage 89.03% 89.82% +0.79%
==========================================
Files 33 33
Lines 7751 7817 +66
==========================================
+ Hits 6901 7022 +121
+ Misses 850 795 -55
Flags with carried forward coverage won't be shown. Click here to find out more.
... and 2 files with indirect coverage changes 🚀 New features to boost your workflow:
|
Windows CI renders skill-md.hbs with CRLF line endings, causing
starts_with("---\n") assertions to fail. Normalize after rendering.
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Summary
server list/info/validatenow read from~/.claude/mcp.json(same source asintrospect/generate). RemovesServerManagerand all Claude Desktop config logic. Missing config file returns an empty list instead of an error.skillCLI writesSKILL.mddirectly via a new Handlebars template, atomically (temp + rename). Frontmatter values are YAML-quoted. Replaces the misleading JSON context dump + false "Output path" log.// ...and/* */comments (bounded at the first string-literal delimiter to avoid false truncation on URL types). Eliminatesdefault/includefalse-positive parameters.Breaking change
skillcommand stdout shape changed from a rawGenerateSkillResultJSON dump to aSkillWriteResultobject (success,output_path,bytes_written,tool_count).Test plan
cargo nextest run --workspace --all-features— 639/639 passcargo +nightly fmt --check— cleancargo clippy --all-targets --all-features --workspace -- -D warnings— cleancargo test --doc --all-features --workspace— 10/10 passserver listreturns[]when~/.claude/mcp.jsonis absent (not an error)skill --server <id>writesSKILL.mdto~/.claude/skills/<id>/SKILL.mdskill --server <id> --format jsonoutputsSkillWriteResultJSONname: string; /* required */andname: string; // commentboth produce paramnamedefault:andinclude:tokens do not appear as parametersCloses #81, #82, #83