fix: strip skills prefix from bare skill plugin export#738
Open
zeel2104 wants to merge 2 commits intomicrosoft:mainfrom
Open
fix: strip skills prefix from bare skill plugin export#738zeel2104 wants to merge 2 commits intomicrosoft:mainfrom
zeel2104 wants to merge 2 commits intomicrosoft:mainfrom
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Fixes incorrect skills/skills/ directory nesting when exporting plugin bundles for bare-skill dependencies referenced via virtual paths like skills/<name>, aligning packed output with plugin.json expectations and the plugin host directory convention.
Changes:
- Normalize bare-skill slugs derived from dependency
virtual_pathby stripping leadingskills/prefixes before emitting bundle paths. - Add unit + end-to-end regression tests to ensure
apm pack --format pluginplaces bare skills underskills/<skill-name>/(no duplicatedskills/).
Show a summary per file
| File | Description |
|---|---|
src/apm_cli/bundle/plugin_exporter.py |
Adds _normalize_bare_skill_slug() and uses it in _collect_bare_skill() to prevent skills/skills/ nesting for virtual_path="skills/<name>". |
tests/unit/test_plugin_exporter.py |
Adds regression coverage for slug normalization and for the full plugin export path to ensure no duplicated skills/ directory is produced. |
Copilot's findings
- Files reviewed: 2/2 changed files
- Comments generated: 0
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.
Description
Fix duplicated
skills/skills/nesting inapm pack --format pluginfor bare skill dependencies referenced through virtual paths likeskills/<name>.The exporter now normalizes bare-skill slugs before writing bundle paths, so dependencies such as
github/awesome-copilot/skills/javascript-typescript-jestpack toskills/javascript-typescript-jest/as expected. Added regression coverage for both the collector helper and the end-to-end plugin export path.Fixes #719
Type of change
Testing