Summary
Implement plugin coexistence support per WIP/plugin-coexistence-spec-v2.md. This makes APM the supply chain layer FOR the plugin ecosystem by enabling APM-authored packages to be exported as valid standalone Copilot CLI / Claude Code plugin directories.
Key Changes
Phase 1: apm pack --format plugin
- New
plugin_exporter.py module transforms .apm/ layout → plugin-native directory
- Maps agents, skills, prompts→commands, instructions, hooks, MCP configs
- Generates output
plugin.json (from existing or synthesized from apm.yml)
- Flattens dependency components with lockfile-order-wins collision model
- Filters out
devDependencies from output
- Output is a valid standalone plugin — no APM runtime needed to consume
Phase 2: apm init --plugin
- New
--plugin flag creates plugin.json + apm.yml (2 files, nothing else)
- Name validation per plugin spec (kebab-case, max 64 chars)
Phase 3: devDependencies full support
APMPackage model: dev_dependencies field
apm install --dev flag
- Resolver + lockfile
is_dev tracking
- Pack excludes dev deps from output
Phase 4: Pure plugin consumption polish
- Root-level discovery patterns for plugin-native repos
- Verify end-to-end install of
plugin.json-only repos
Design Decisions
.apm/ layout retained — no deprecation, no migration
apm pack default behavior unchanged — plugin export is behind --format plugin
- No breaking changes — all new functionality behind flags
- Zero vendor lock-in: plugin output needs no APM runtime
Spec
See WIP/plugin-coexistence-spec-v2.md for full specification.
Summary
Implement plugin coexistence support per
WIP/plugin-coexistence-spec-v2.md. This makes APM the supply chain layer FOR the plugin ecosystem by enabling APM-authored packages to be exported as valid standalone Copilot CLI / Claude Code plugin directories.Key Changes
Phase 1:
apm pack --format pluginplugin_exporter.pymodule transforms.apm/layout → plugin-native directoryplugin.json(from existing or synthesized fromapm.yml)devDependenciesfrom outputPhase 2:
apm init --plugin--pluginflag createsplugin.json+apm.yml(2 files, nothing else)Phase 3:
devDependenciesfull supportAPMPackagemodel:dev_dependenciesfieldapm install --devflagis_devtrackingPhase 4: Pure plugin consumption polish
plugin.json-only reposDesign Decisions
.apm/layout retained — no deprecation, no migrationapm packdefault behavior unchanged — plugin export is behind--format pluginSpec
See
WIP/plugin-coexistence-spec-v2.mdfor full specification.