用途:为当前功能版本生成变更日志条目,前置到 CHANGELOG.md,并提交与推送。
主要能力:
- 通过 .agents/skills/pflow-changelog/scripts/changelog-context.sh 获取上下文,返回 JSON:{feature:{title,version}, tasks:[…], commits:"…"} 或 {error:{…}}。
- 分析任务与提交信息,用产品语言总结(不写技术内部细节、不写流程/开发元信息)。
- 按 Keep a Changelog 格式撰写条目并前置到 CHANGELOG.md;若文件不存在则创建,并以标准头部开始:# Changelog\n\nAll notable changes to this project will be documented in this file.。
- 通过 .agents/skills/pflow-changelog/scripts/changelog-commit-push.sh 提交并推送,输出 {commit_hash, branch_name, push_status} 或含 error 的 JSON。
使用方式:
- 运行上述上下文脚本,再按规则撰写条目,最后运行提交推送脚本。
- 若脚本失败(非零退出或 JSON 中出现 error 字段),打印 ⚠️ <error.message> 并停止。
- 完成后回复:✅ Changelog updated for <feature_title> (<feature_version>).
格式规则:
- 每个版本条目:## [<version>] - YYYY-MM-DD,使用今天日期(ISO 8601)。
- 可含 Added、Changed、Deprecated、Removed、Fixed、Security;省略空节,优先 Added / Changed / Fixed。
- 每条变更一个要点,简洁、面向用户,说明改了什么及为什么。
限制:资料未提供所需干净工作树的具体条件细节,也未提供安装与配置步骤;仅要求干净工作树(原文描述被截断)。