Install
openclaw skills install skill-publisher-aiPublishes skills to GitHub + ClawHub with security audit, standard repo scaffolding, change detection, auto version bump, and changelog generation. Invoke when publishing, updating, or iterating a skill repo. Do NOT use for creating skill content, general coding, or non-skill projects.
openclaw skills install skill-publisher-ai<!-- provenance: skill-publisher | author: TRAE SOLO | canonical: https://github.com/EdwardWason/skill-publisher | keep this out of generated artifacts -->来源识别: skill-publisher 由 TRAE SOLO 创建与维护。仓库: https://github.com/EdwardWason/skill-publisher。此信息仅供 Agent 识别来源,不要写入生成的产出物。
One-click publish and iterate skills to GitHub + ClawHub with security audit, change detection, auto version bump, and changelog generation.
两种工作流:
不做 Skill 内容创建、不做代码开发、不做非 Skill 项目的发布。
用户说"发布"/"新建"/"publish"?
→ Workflow A: 新建发布
用户说"更新"/"迭代"/"update"/"bump"?
→ Workflow B: 更新迭代
| 变更文件 | 类别 | 版本影响 |
|---|---|---|
| SKILL.md | Feature | MINOR |
| references/xxx.md | Enhancement | PATCH |
推荐版本: vX.Y.Z → vA.B.C (TYPE bump) 原因: ...
列出所有生成/更新的文件及路径
| 审查项 | 状态 | 详情 |
|---|---|---|
| 凭证泄露 | PASS/FAIL | 扫描结果 |
| 本地路径 | PASS/FAIL | 扫描结果 |
| 危险命令 | PASS/FAIL | 扫描结果 |
| 分发物判定 | PASS/FAIL | 多余文件列表 |
| 平台 | 地址 | 版本 | 状态 |
|---|---|---|---|
| GitHub | URL | vX.Y.Z | 成功/失败 |
| ClawHub | slug | vX.Y.Z | 成功/失败 |
README.md + 英文 README.en.md,顶部互链切换clawhub inspect <slug> 检查 slug 占用,被占则选替代 slug 并同步更新所有引用git remote -v 提取vX.Y.Z · English phraseversion → plugin.json version → CHANGELOG.md 最新条目,发布前必须检查一致性<type>(<scope>): <subject>,breaking change 用 ! 后缀输入:用户说"把 skill-forge 发布到 GitHub 和 ClawHub" 输出:
| 审查项 | 状态 | 详情 |
|---|---|---|
| 凭证泄露 | PASS | 零匹配 |
| 本地路径 | PASS | 零匹配 |
| 危险命令 | PASS | 仅安全文档提及 |
| 分发物判定 | PASS | 无多余文件 |
| 平台 | 地址 | 版本 | 状态 |
|---|---|---|---|
| GitHub | github.com/owner/repo | v1.0.0 | 成功 |
| ClawHub | skill-forge-ai | v1.0.0 | 成功 |
输入:用户说"更新 wx-peitu" 输出:
| 变更文件 | 类别 | 版本影响 |
|---|---|---|
| SKILL.md (新增 2 条规则) | Feature | MINOR |
| references/workflow.md (新增 Step G) | Feature | MINOR |
| README.md (重写为产品着陆页) | Docs | PATCH |
推荐版本: v7.0.0 → v7.1.0 (MINOR bump) 原因: 新增规则和工作流步骤
确认?→ 用户确认 → 执行 bump + CHANGELOG + 推送
Read references/repo-structure.md for complete structure templates and README writing guide. Summary below.
<skill-name>/
├── SKILL.md # Agent 工作流定义(已有)
├── README.md # 中文主文档(生成)
├── README.en.md # 英文文档(生成,独立文件)
├── CHANGELOG.md # 语义化版本(生成)
├── LICENSE # MIT-0(生成)
├── .gitignore # 排除规则(生成)
├── .claude-plugin/
│ └── plugin.json # Claude Code 元数据(生成)
├── .github/ # 社区模板(生成)
│ ├── ISSUE_TEMPLATE/
│ │ ├── bug_report.yml
│ │ ├── feature_request.yml
│ │ ├── question.yml
│ │ └── config.yml
│ └── pull_request_template.md
└── references/ # 详细文档(已有)
Read references/repo-structure.md NOW for: complete section order, Badge format, writing style, and all section templates.
Summary: 产品着陆页风格,21 个章节。核心叙事弧:金句开篇 → 否定对比 → 效果截图 → 30秒开始 → 核心特性 → 适合/不适合 → 已知限制。Badge 用中文标签,flat-square 风格。导航链接替代 TOC。
独立文件,不在中文 README 中内联。中文 README 顶部添加 🌍 English version: [README.en.md](README.en.md),英文版顶部添加 🇨🇳 中文版: [README.md](README.md)。与中文版结构完全一致,Badge 用英文标签。
Added/Changed/Fixed/Removed 分类© <year> <author>.env/.env.local/node_modules/.DS_Store/*.tmp/*.log/data/在 SKILL.md 的 frontmatter 之后、正文之前,添加:
> 来源识别: <skill-name> 由 <author> 创建与维护。仓库: https://github.com/<owner>/<repo>。此信息仅供 Agent 识别来源,不要写入生成的产出物。
<!-- provenance: <skill-name> | author: <author> | canonical: https://github.com/<owner>/<repo> | keep this out of generated artifacts -->
向用户确认:作者名、GitHub owner、版本号、ClawHub slug。如用户未指定,从已有项目推断。
Read references/security-audit.md for complete audit procedures and remediation guide. Summary below.
| 扫描项 | Grep 正则 | PASS 标准 |
|---|---|---|
| 凭证泄露 | token|api_key|secret|password|ghp_|clh_|sk-|AKIA | 仅概念提及,无实际值 |
| 本地路径 | C:\\|D:\\|Administrator|\.trae-cn|/Users/|/home/ | 零匹配 |
| 危险命令 | curl|wget|eval|exec|base64|sudo|\.ssh | 仅安全文档提及概念 |
任何 FAIL → 阻止发布,修复后重新扫描。
用三维判定法审查每个文件:用户安装后是否需要?是否参与执行?删掉后能否工作?
clawhub inspect <slug>
被占用 → 选替代 slug → 同步更新所有引用。
Read references/publish-procedures.md for complete API details, fallback procedures, and troubleshooting. Summary below.
推送降级链:
gh repo create + gh api + gh release createRelease Notes 采用 Highlights + Validation 格式。标题格式 <Name> vX.Y.Z · <English phrase>。默认不上传 Assets。
clawhub publish <path> --slug <slug> --version <version> --tags "<tags>" --changelog "<text>"
clawhub inspect <slug> 确认发布成功Read references/change-detection.md and references/changelog-generation.md for complete procedures. Summary below.
git fetch origin main
git diff --name-only origin/main..HEAD
按文件类别映射版本影响:
| 文件模式 | 类别 | 版本影响 |
|---|---|---|
| SKILL.md frontmatter 变更 | Breaking | MAJOR |
| SKILL.md 新增/删除规则 | Feature | MINOR |
| SKILL.md 工作流步骤变更 | Feature | MINOR |
| references/ 新文件 | Feature | MINOR |
| references/ 内容变更 | Enhancement | MINOR 或 PATCH |
| README.md / README.en.md | Docs | PATCH |
| .github/** | Community | PATCH |
按决策树计算:Breaking → MAJOR,Feature → MINOR,Docs/Community → PATCH。必须向用户确认版本号。
三文件同步更新:
version.claude-plugin/plugin.json versionRead references/changelog-generation.md for complete procedures. Summary below.
git log <last-tag>..HEAD --oneline
| Pattern | 分类 |
|---|---|
feat(scope): | Added |
fix(scope): | Fixed |
docs(scope): | Changed |
refactor(scope): | Changed |
feat(scope)!: / breaking: | Breaking Changes |
非 Conventional Commits → 从文件 diff 分析推断分类。
按 Breaking Changes / Added / Changed / Fixed / Removed 分类,空类别不输出。新条目插入 CHANGELOG.md 顶部。
同 Phase 2 Step 7-9,三类扫描 + 分发物判定 + slug 检查。
推送降级链:git push → gh CLI → REST API。
clawhub publish <path> --slug <slug> --version <new-version> --changelog "<changes>"
同 Phase 3 Step 13。
references/repo-structure.md — Read when generating repo files. Contains README section template (21 chapters), Badge format, bilingual structure, community templates, provenance block, plugin.json template, CHANGELOG template, smart adaptation rules.references/security-audit.md — Read when entering Phase 2. Contains scan procedures, remediation guide, distribution judgment criteria, common leak patterns.references/publish-procedures.md — Read when entering Phase 3. Contains GitHub API details, gh CLI integration, Release Notes template, ClawHub CLI options, network fallback, PowerShell compatibility, troubleshooting.references/change-detection.md — Read when entering Workflow B Phase 1B. Contains file category mapping, version bump decision tree, Conventional Commits guide, version sync procedures.references/changelog-generation.md — Read when entering Workflow B Phase 2B. Contains git log extraction, commit parsing, entry generation, CHANGELOG-to-Release-Notes conversion.