prepare-release by cherryhq/cherry-studio
npx skills add https://github.com/cherryhq/cherry-studio --skill prepare-release自动化 Cherry Studio 的发布工作流程:收集变更 → 生成双语发布说明 → 更新文件 → 创建发布分支 + PR → 触发 CI/CD。
从用户的消息中解析版本意图。接受以下任何形式:
patch、minor、majorx.y.z 或 x.y.z-pre.N(例如 1.8.0、1.8.0-beta.1、1.8.0-rc.1)如果未指定版本,则默认为 patch。在进行任何文件编辑之前,始终向用户回显解析出的目标版本。
广告位招租
在这里展示您的产品或服务
触达数万 AI 开发者,精准高效
--dry-run:仅预览,不创建分支或 PR。获取最新的标签:
git describe --tags --abbrev=0
从 package.json 读取当前版本。
根据参数计算新版本:
patch / minor / major:基于当前标签版本进行升级。x.y.z 或 x.y.z-pre.N:在验证其为有效的 semver 后直接使用。列出自上一个标签以来的所有提交:
git log <last-tag>..HEAD --format="%H %s" --no-merges
对于每个提交,获取完整的正文:
git log <hash> -1 --format="%B"
从每个提交正文中提取 ````release-note` 代码块内的内容。
从标题中提取约定式提交类型(feat、fix、refactor、perf、docs 等)。
跳过以下提交:
🤖 Daily Auto I18N 开头Merge 开头chore(deps) 开头chore: release 开头NONE 的提交使用收集到的提交信息,生成英文和中文的发布说明。
格式(必须完全匹配):
<!--LANG:en-->
Cherry Studio {version} - {Brief English Title}
✨ New Features
- [Component] Description
🐛 Bug Fixes
- [Component] Description
💄 Improvements
- [Component] Description
⚡ Performance
- [Component] Description
<!--LANG:zh-CN-->
Cherry Studio {version} - {简短中文标题}
✨ 新功能
- [组件] 描述
🐛 问题修复
- [组件] 描述
💄 改进
- [组件] 描述
⚡ 性能优化
- [组件] 描述
<!--LANG:END-->
规则:
release-note 字段,则使用它;否则根据提交标题进行总结。[Chat]、[Models]、[Agent]、[MCP]、[Settings]、[Data]、[Build] 等。electron-builder.yml 中现有的发布说明作为风格参考。package.json:将 "version" 字段更新为新版本。electron-builder.yml:将 releaseInfo.releaseNotes: | 下的内容替换为生成的说明。保留块标量内容的 4 空格 YAML 缩进。向用户展示:
如果指定了 --dry-run,则在此处停止。
否则,在继续执行步骤 6 之前,请用户确认。
创建并推送发布分支:
git checkout -b release/v{version}
git add package.json electron-builder.yml
git commit -m "chore: release v{version}"
git push -u origin release/v{version}
使用 gh-create-pr skill 创建 PR。如果该技能工具不可用,请阅读 .agents/skills/gh-create-pr/SKILL.md 并手动遵循其步骤。在 CI(非交互式)模式下,跳过交互式确认步骤,在填写模板后直接创建 PR。
chore: release v{version}mainelectron-builder.yml 中生成的发布说明package.json 中的版本升级报告 PR URL 和后续步骤。
从 release/v* 创建到 main 的 PR 会自动触发:
release.yml:在 macOS、Windows、Linux 上构建并创建草稿 GitHub Release。ci.yml:运行代码检查、类型检查和测试。electron-builder.yml 之前,始终先读取它以了解当前格式。package.json 和 electron-builder.yml 以外的文件。main 分支。每周安装次数
1
仓库
GitHub 星标数
41.0K
首次出现
5 天前
安全审计
安装于
mcpjam1
github-copilot1
junie1
windsurf1
zencoder1
crush1
Automate the Cherry Studio release workflow: collect changes → generate bilingual release notes → update files → create release branch + PR → trigger CI/CD.
Parse the version intent from the user's message. Accept any of these forms:
patch, minor, majorx.y.z or x.y.z-pre.N (e.g. 1.8.0, 1.8.0-beta.1, 1.8.0-rc.1)Defaults to patch if no version is specified. Always echo the resolved target version back to the user before proceeding with any file edits.
--dry-run: Preview only, do not create branch or PR.Get the latest tag:
git describe --tags --abbrev=0
Read current version from package.json.
Compute the new version based on the argument:
patch / minor / major: bump from the current tag version.x.y.z or x.y.z-pre.N: use as-is after validating it is valid semver.List all commits since the last tag:
git log <last-tag>..HEAD --format="%H %s" --no-merges
For each commit, get the full body:
git log <hash> -1 --format="%B"
Extract the content inside ````release-note` code blocks from each commit body.
Extract the conventional commit type from the title (feat, fix, refactor, perf, docs, etc.).
Skip these commits:
🤖 Daily Auto I18NUsing the collected commit information, generate release notes in both English and Chinese.
Format (must match exactly):
<!--LANG:en-->
Cherry Studio {version} - {Brief English Title}
✨ New Features
- [Component] Description
🐛 Bug Fixes
- [Component] Description
💄 Improvements
- [Component] Description
⚡ Performance
- [Component] Description
<!--LANG:zh-CN-->
Cherry Studio {version} - {简短中文标题}
✨ 新功能
- [组件] 描述
🐛 问题修复
- [组件] 描述
💄 改进
- [组件] 描述
⚡ 性能优化
- [组件] 描述
<!--LANG:END-->
Rules:
release-note field if present; otherwise summarize from the commit title.[Chat], [Models], [Agent], [MCP], [Settings], [Data], [Build], etc.electron-builder.yml as a style reference before writing.package.json : Update the "version" field to the new version.electron-builder.yml : Replace the content under releaseInfo.releaseNotes: | with the generated notes. Preserve the 4-space YAML indentation for the block scalar content.Show the user:
If --dry-run was specified, stop here.
Otherwise, ask the user to confirm before proceeding to Step 6.
Create and push the release branch:
git checkout -b release/v{version}
git add package.json electron-builder.yml
git commit -m "chore: release v{version}"
git push -u origin release/v{version}
Create the PR using the gh-create-pr skill. If the skill tool is unavailable, read .agents/skills/gh-create-pr/SKILL.md and follow it manually. In CI (non-interactive) mode, skip interactive confirmation steps and create the PR directly after filling the template.
chore: release v{version}mainelectron-builder.ymlCreating a PR from release/v* to main automatically triggers:
release.yml : Builds on macOS, Windows, Linux and creates a draft GitHub Release.ci.yml : Runs lint, typecheck, and tests.electron-builder.yml before modifying it to understand the current format.package.json and electron-builder.yml.main.Weekly Installs
1
Repository
GitHub Stars
41.0K
First Seen
5 days ago
Security Audits
Gen Agent Trust HubPassSocketPassSnykPass
Installed on
mcpjam1
github-copilot1
junie1
windsurf1
zencoder1
crush1
Azure Data Explorer (Kusto) 查询技能:KQL数据分析、日志遥测与时间序列处理
114,200 周安装
Docnify自动化:通过Rube MCP和Composio工具包实现文档操作自动化
1 周安装
Docmosis自动化集成指南:通过Rube MCP与Composio实现文档生成自动化
1 周安装
Dictionary API自动化教程:通过Rube MCP和Composio实现词典API操作自动化
1 周安装
detrack-automation:自动化追踪技能,集成Claude AI提升开发效率
1 周安装
Demio自动化工具包:通过Rube MCP和Composio实现Demio操作自动化
1 周安装
Deel自动化工具:通过Rube MCP与Composio实现HR与薪资操作自动化
1 周安装
Mergechore(deps)chore: releaseNONEpackage.jsonReport the PR URL and next steps.