--- topic: compile source_keys: - context7-microsoft-apm --- ## Compile ```bash apm compile ``` Generates per-target output (Claude, Copilot, etc.) from the vendor-neutral `.apm/` primitive source tree, per the `compilation:` block in `apm.yml`. Run this after any change to `.apm/` content or to `compilation:`/`targets:` in `apm.yml`. ## Pack ```bash apm pack --dry-run # resolve and print; do not write apm pack --offline # cached refs only apm pack --include-prerelease # allow pre-release tags apm pack -v # per-entry resolution detail apm pack --marketplace=claude --json # JSON output for CI pipelines ``` Bundles a producer package into a distributable artifact. Default to `--dry-run -v` first when packing something for the first time or after a dependency change — resolution errors surface before anything is written. ## Publish ```bash apm publish --package acme/my-skill --dry-run -v apm publish --package acme/my-skill ``` Publishes a producer package (root containing `apm.yml`, `.apm/`, and optionally a `registries:` block) to a registry. Always dry-run with `-v` first — publishing is not trivially reversible once a version tag is claimed on a registry. ## Run ```bash apm run