Make the skill directory self-contained so both install paths work - #10
Merged
Conversation
Moving SKILL.md under skills/ in the previous commit broke the plain personal-skill
install: a symlink at ~/.claude/skills/claude-translator pointing at the repo root no
longer resolved to a SKILL.md, and the skill silently disappeared.
The previous commit assumed a directory in ~/.claude/skills/ carrying a
.claude-plugin/plugin.json would be auto-loaded as a plugin instead. That is not true
on Claude Code 2.1.126 — claude plugin list reports nothing installed — so the README
claim was wrong and is removed.
references/ now lives inside skills/translate-site/, making the skill directory
self-contained. One copy then serves both paths: as a plugin, and as a plain skill
symlinked directly into ~/.claude/skills/. The reference links go back to plain
relative paths; only LICENSING.md and i18n.config.example.json, which stay at the repo
root, keep ${CLAUDE_PLUGIN_ROOT}. README links and the npm files list follow the move.
Verified both ways against the final layout: the plugin loads through --plugin-dir as
conveythis-translator:<skill>, and the symlinked skill directory is discovered as a
personal skill. claude plugin validate passes clean, npm run check and all 39 tests
pass, and npm pack ships the manifest, the skill and its references.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
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.
Follow-up to #9, fixing a regression it introduced.
What broke
Moving
SKILL.mdunderskills/broke the plain personal-skill install. A symlink at~/.claude/skills/claude-translatorpointing at the repo root no longer resolved to aSKILL.md, and the skill silently disappeared from Claude's skill list.#9 assumed a directory in
~/.claude/skills/carrying a.claude-plugin/plugin.jsonwould be auto-loaded as a plugin instead. That is not true on Claude Code 2.1.126 —claude plugin listreports nothing installed. The README claim to that effect was wrong and is removed.The fix
references/moves intoskills/translate-site/references/, making the skill directory self-contained. One copy then serves both install paths:--plugin-dirskills/translate-sitedirectly into~/.claude/skills/Reference links in the skill go back to plain relative paths. Only
LICENSING.mdandi18n.config.example.json, which stay at the repo root, keep${CLAUDE_PLUGIN_ROOT}. README links and the npmfileslist follow the move.Verification
Both paths checked against the final layout:
--plugin-dirasconveythis-translator:<skill>, confirmed with a uniquely renamed copy so no already-installed skill could be mistaken for itclaude plugin validate .passes with no errors and no warningsnpm run checkand all 39 tests pass;npm packships the manifest, the skill and its references🤖 Generated with Claude Code