Publish Plugin Packager
Package existing skills into standard, release-ready plugin or bundle formats for ClawHub, Claude marketplace, GitHub distribution, and related runtimes.
When to use
- When converting an existing skill into a publishable plugin or bundle
- When generating or fixing manifests such as
package.json, .claude-plugin/plugin.json, or openclaw.plugin.json
- When creating the final runtime-only directory and zip structure for upload or distribution
- When producing a release artifact from an already-optimized source skill
When NOT to use
- When the deliverable is only a
SKILL.md optimization; use clawhub-skill-optimizer
- When the main task is auditing upload risk; use
clawhub-security-auditor
- When the main work is rewriting runtime behavior rather than packaging it
Scope boundary
This skill owns:
- plugin or bundle directory structure
- manifest generation
- release layout and zip shape
- packaging validation
This skill does not own:
- primary search-copy optimization
- deep Suspicious/security auditing
- large runtime refactors beyond what packaging requires
Packaging targets
Choose the artifact first:
runtime skill bundle
- for direct GitHub distribution or skill-layer publishing
- keeps the skill directory itself as the primary artifact
ClawHub bundle plugin
.claude-plugin/plugin.json plus minimal package.json
- best for pure skill collections
ClawHub code plugin
openclaw.plugin.json plus package.json
- use when config schema, native extensions, or code entrypoints are required
Claude marketplace plugin
.claude-plugin/plugin.json and marketplace-compatible layout
- wraps an already-trimmed skill for Claude plugin distribution
Source skill hard conventions
Before packaging, validate that the source skill follows these repository conventions:
- Published source skills should use
name, description, and canonical metadata.aisa.
metadata.aisa should normally contain emoji, requires, primaryEnv, and compatibility.
- Command examples should use
{baseDir} rather than bootstrap-only variables.
- Package only runtime-essential files by default:
SKILL.md, runtime scripts, libraries, manifests, and minimal wrappers.
- Exclude compare, evaluate, test, sync, migration, and dev utilities unless the user explicitly asks for a developer bundle.
- If the repo keeps a richer mother skill plus publish bundles, preserve the mother skill and trim only the publish bundles.
- Prefer repo-local config and data defaults over home-directory defaults when the packaged runtime persists files.
- If both EN and ZH variants are published, validate that both variants were trimmed with the same runtime and safety policy.
Packaging workflow
- Analyze the source skill and the target platform.
- Determine the artifact type:
- raw runtime bundle
- ClawHub bundle plugin
- ClawHub code plugin
- Claude marketplace plugin
- Normalize the shipped file set:
- keep runtime files
- drop caches, tests, sync scripts, and packaging-only helpers
- Generate the correct manifests.
- Preserve core skill semantics inside
skills/<skill-name>/.
- Validate the package layout and manifest fields.
- Create a root-level release zip so required files sit directly at the zip root.
Preserve core skill content
The content within skills/<skill-name>/, especially SKILL.md, should remain semantically intact during packaging. The packager may:
- remove non-runtime helpers from the release bundle
- trim caches, logs, and generated artifacts
- add platform manifests and wrapper files
The packager should not:
- silently rewrite the skill's core workflow
- introduce new auth paths
- broaden the runtime surface just to satisfy packaging convenience
Real upload lessons
Recent real uploads were flagged for these concrete reasons:
- External CLI execution inside shipped helpers
- Self-install or cache-sync behavior
- Default writes into user-home data locations
- Version-swapping or repo-mutation helpers
- Shipping non-runtime test/compare/sync utilities
- Aggressive data-retention wording
- Browser cookie, Keychain, or local credential access helpers
- Legacy secret inputs left in runtime config
Required packager behavior:
- bundle only runtime-essential files by default
- exclude helper scripts that invoke external CLIs or mutate local installs
- prefer repo-local persistence when persistence is required
- do not include
__pycache__, .pytest_cache, logs, debug artifacts, or non-text binaries in release zips
- exclude deprecated multi-provider auth paths from API-key-only bundles
- apply the same safety trimming to EN and ZH variants
Layout rules
ClawHub bundle plugin
plugin-name/
├── .claude-plugin/
│ └── plugin.json
├── package.json
├── skills/
│ └── skill-name/
│ ├── SKILL.md
│ └── ...
└── README.md
ClawHub code plugin
plugin-name/
├── openclaw.plugin.json
├── package.json
├── skills/
│ └── skill-name/
│ └── SKILL.md
└── README.md
Claude marketplace plugin
plugin-name/
├── .claude-plugin/
│ └── plugin.json
├── package.json
├── skills/
│ └── skill-name/
│ ├── SKILL.md
│ └── ...
└── README.md
Zip rule
The release zip should place package.json, manifests, skills/, and other required root files directly at the root of the archive, not inside an extra package/ folder.
Example requests
Package this runtime skill as a ClawHub bundle plugin
Wrap this release skill as a Claude marketplace plugin
Trim this repo down to a publishable runtime bundle and zip it correctly
Generate the manifests for this code plugin without changing the skill semantics
1---2name: clawhub-plugin-packager3description: Package skills into publishable plugin or bundle formats for ClawHub, Claude marketplace, and related runtimes. Use when: converting a skill into a plugin or release bundle, generating manifests, and assembling a release-ready upload directory. Not for standalone metadata optimization or deep security auditing.4---56# Publish Plugin Packager78Package existing skills into standard, release-ready plugin or bundle formats for ClawHub, Claude marketplace, GitHub distribution, and related runtimes.910## When to use1112- When converting an existing skill into a publishable plugin or bundle13- When generating or fixing manifests such as `package.json`, `.claude-plugin/plugin.json`, or `openclaw.plugin.json`14- When creating the final runtime-only directory and zip structure for upload or distribution15- When producing a release artifact from an already-optimized source skill1617## When NOT to use1819- When the deliverable is only a `SKILL.md` optimization; use `clawhub-skill-optimizer`20- When the main task is auditing upload risk; use `clawhub-security-auditor`21- When the main work is rewriting runtime behavior rather than packaging it2223## Scope boundary2425This skill owns:2627- plugin or bundle directory structure28- manifest generation29- release layout and zip shape30- packaging validation3132This skill does not own:3334- primary search-copy optimization35- deep Suspicious/security auditing36- large runtime refactors beyond what packaging requires3738## Packaging targets3940Choose the artifact first:4142- `runtime skill bundle`43 - for direct GitHub distribution or skill-layer publishing44 - keeps the skill directory itself as the primary artifact45- `ClawHub bundle plugin`46 - `.claude-plugin/plugin.json` plus minimal `package.json`47 - best for pure skill collections48- `ClawHub code plugin`49 - `openclaw.plugin.json` plus `package.json`50 - use when config schema, native extensions, or code entrypoints are required51- `Claude marketplace plugin`52 - `.claude-plugin/plugin.json` and marketplace-compatible layout53 - wraps an already-trimmed skill for Claude plugin distribution5455## Source skill hard conventions5657Before packaging, validate that the source skill follows these repository conventions:5859- Published source skills should use `name`, `description`, and canonical `metadata.aisa`.60- `metadata.aisa` should normally contain `emoji`, `requires`, `primaryEnv`, and `compatibility`.61- Command examples should use `{baseDir}` rather than bootstrap-only variables.62- Package only runtime-essential files by default: `SKILL.md`, runtime scripts, libraries, manifests, and minimal wrappers.63- Exclude compare, evaluate, test, sync, migration, and dev utilities unless the user explicitly asks for a developer bundle.64- If the repo keeps a richer mother skill plus publish bundles, preserve the mother skill and trim only the publish bundles.65- Prefer repo-local config and data defaults over home-directory defaults when the packaged runtime persists files.66- If both EN and ZH variants are published, validate that both variants were trimmed with the same runtime and safety policy.6768## Packaging workflow69701. Analyze the source skill and the target platform.712. Determine the artifact type:72 - raw runtime bundle73 - ClawHub bundle plugin74 - ClawHub code plugin75 - Claude marketplace plugin763. Normalize the shipped file set:77 - keep runtime files78 - drop caches, tests, sync scripts, and packaging-only helpers794. Generate the correct manifests.805. Preserve core skill semantics inside `skills/<skill-name>/`.816. Validate the package layout and manifest fields.827. Create a root-level release zip so required files sit directly at the zip root.8384## Preserve core skill content8586The content within `skills/<skill-name>/`, especially `SKILL.md`, should remain semantically intact during packaging. The packager may:8788- remove non-runtime helpers from the release bundle89- trim caches, logs, and generated artifacts90- add platform manifests and wrapper files9192The packager should not:9394- silently rewrite the skill's core workflow95- introduce new auth paths96- broaden the runtime surface just to satisfy packaging convenience9798## Real upload lessons99100Recent real uploads were flagged for these concrete reasons:1011021. External CLI execution inside shipped helpers1032. Self-install or cache-sync behavior1043. Default writes into user-home data locations1054. Version-swapping or repo-mutation helpers1065. Shipping non-runtime test/compare/sync utilities1076. Aggressive data-retention wording1087. Browser cookie, Keychain, or local credential access helpers1098. Legacy secret inputs left in runtime config110111Required packager behavior:112113- bundle only runtime-essential files by default114- exclude helper scripts that invoke external CLIs or mutate local installs115- prefer repo-local persistence when persistence is required116- do not include `__pycache__`, `.pytest_cache`, logs, debug artifacts, or non-text binaries in release zips117- exclude deprecated multi-provider auth paths from API-key-only bundles118- apply the same safety trimming to EN and ZH variants119120## Layout rules121122### ClawHub bundle plugin123124```text125plugin-name/126├── .claude-plugin/127│ └── plugin.json128├── package.json129├── skills/130│ └── skill-name/131│ ├── SKILL.md132│ └── ...133└── README.md134```135136### ClawHub code plugin137138```text139plugin-name/140├── openclaw.plugin.json141├── package.json142├── skills/143│ └── skill-name/144│ └── SKILL.md145└── README.md146```147148### Claude marketplace plugin149150```text151plugin-name/152├── .claude-plugin/153│ └── plugin.json154├── package.json155├── skills/156│ └── skill-name/157│ ├── SKILL.md158│ └── ...159└── README.md160```161162## Zip rule163164The release zip should place `package.json`, manifests, `skills/`, and other required root files directly at the root of the archive, not inside an extra `package/` folder.165166## Example requests167168- `Package this runtime skill as a ClawHub bundle plugin`169- `Wrap this release skill as a Claude marketplace plugin`170- `Trim this repo down to a publishable runtime bundle and zip it correctly`171- `Generate the manifests for this code plugin without changing the skill semantics`