com um clique
cx-summary
CX 工作流 — 汇总发布与闭环。手动触发或在所有任务完成后进入。 负责生成总结、同步 GitHub 镜像、清理当前 feature 指针。
Instalar com Codex ou Claude Copie este prompt, cole no Codex, Claude ou outro assistente e deixe que ele revise a página da skill e instale para você.
Menu
CX 工作流 — 汇总发布与闭环。手动触发或在所有任务完成后进入。 负责生成总结、同步 GitHub 镜像、清理当前 feature 指针。
Instalar com Codex ou Claude Copie este prompt, cole no Codex, Claude ou outro assistente e deixe que ele revise a página da skill e instale para você.
Baseado na classificação ocupacional SOC
CX 工作流 — 配置管理。查看或修改项目级 `开发文档/CX工作流/配置.json` 中公开的少量字段。仅在用户明确调用 `/cx:cx-config` 时执行。
CX 工作流 — Bug 修复。当用户提到"修 bug"、"fix"、"报错"、"debug"、 "修复"时触发。默认走快速修复路径,复杂问题再升级为更深入的调查。
CX 工作流 — 项目初始化。每个项目都单独确认 developer_id、GitHub 同步策略、 agent teams、code review、worktree isolation、auto memory,并建立项目级 `开发文档/CX工作流 + .cx` 运行时真相目录。仅在用户明确调用 `/cx:cx-init` 时执行。
CX 工作流 — 需求收集与规模评估。当用户提到"新功能"、"需求"、"PRD"、 "我想做一个"、"帮我规划"、"收集需求"、"功能规划"时触发。 多轮对话收集需求,自动评估规模,保存到本地 开发文档/CX工作流/功能/{feature_title}/需求.md,并自动判断是否需要 Design。
CX 工作流 — 项目蓝图探讨。当用户提到"蓝图"、"整体规划"、"项目范围"、 "scope"、"项目探讨"、"功能方案"时触发。多轮对话探讨项目或功能方案, 将结果保存到本地 `开发文档/CX工作流/功能/{功能标题}/范围.md`, 可选同步到 GitHub Issue(基于 config.github_sync 模式)。
Codex 侧 CX 架构决策记录。沉淀设计取舍,不改变 lease 与 worktree 持有关系。
| name | cx-summary |
| description | CX 工作流 — 汇总发布与闭环。手动触发或在所有任务完成后进入。 负责生成总结、同步 GitHub 镜像、清理当前 feature 指针。 |
只负责收尾,不参与执行态主控。
先阅读:
${CLAUDE_PLUGIN_ROOT}/core/workflow/README.md${CLAUDE_PLUGIN_ROOT}/core/workflow/protocols/summary.md/cx:cx-summary
/cx:cx-summary {功能名}
所有文件读写必须使用绝对路径。 禁止使用 ../ 相对路径。先用 git rev-parse --show-toplevel 获取绝对路径。
cx:summary 不负责补救执行问题GitHub 为同步镜像,项目级 开发文档/CX工作流 + .cx 才是真相cc adapter 收尾动作,不会擅自改写其他 runner 的 lease状态.json需求.md / 设计.md / 架构决策.md / 总结.md如果 code_review=true,必须(MUST) 使用 AskUserQuestion 工具询问:
{
"questions": [
{
"question": "闭环前做代码审查吗?",
"header": "Code Review",
"multiSelect": false,
"options": [
{
"label": "全面审查 (Recommended)",
"description": "完整检查代码质量、契约一致性和测试覆盖"
},
{
"label": "快速审查",
"description": "只检查关键路径和明显问题"
},
{
"label": "跳过",
"description": "直接进入总结阶段"
}
]
}
]
}
这一步是闭环前检查,不是执行期主控。
优先调用共享 runner:
bash ${CLAUDE_PLUGIN_ROOT}/scripts/cx-workflow-summary.sh \
--feature <feature-slug> \
--runner cc \
--session-id <session-id>
输出到:
开发文档/CX工作流/功能/{功能标题}/总结.md
总结只回答这些问题:
根据 github_sync 决定是否同步:
off:只保留本地local:轻量同步结果collab / full:同步关键文档和闭环结果但无论哪种模式,GitHub 都不是执行真相源。
检查 feature 的 状态.json 中的 worktree.isolation_mode:
如果 isolation_mode = "worktree"(独立工作区):
必须(MUST) 使用 AskUserQuestion 工具询问合并方式:
{
"questions": [
{
"question": "功能「{feature_title}」已完成,如何合并回主分支?",
"header": "合并方式",
"multiSelect": false,
"options": [
{
"label": "创建 Pull Request (Recommended)",
"description": "推送分支并创建 PR,适合需要 review 的场景"
},
{
"label": "直接合并到主分支",
"description": "将 worktree 分支合并回主分支并清理"
},
{
"label": "暂不合并",
"description": "保留工作区和分支,稍后手动处理"
}
]
}
]
}
选项 1(创建 PR):
git push -u origin worktree-{feature-slug}
gh pr create --title "feat: {feature_title}" --body "..."
选项 2(直接合并):
# 先退出 worktree 回到主目录
ExitWorktree(save: true)
# 在主分支合并
git merge worktree-{feature-slug}
# 清理 worktree 分支
git branch -d worktree-{feature-slug}
选项 3(暂不合并):
git worktree list 查看如果 isolation_mode = "inline"(当前分支直接开发):
如果当前在 feature worktree 中(非 inline 模式),summary 完成后提供整合选项:
使用 AskUserQuestion:
{
"questions": [{
"question": "所有任务已完成,如何处理这个 feature 分支?",
"header": "分支整合",
"multiSelect": false,
"options": [
{ "label": "Merge 回主分支", "description": "合并后删除分支和 worktree" },
{ "label": "Push + 创建 Pull Request", "description": "推送到远程,创建 PR 供审查" },
{ "label": "保留分支(稍后处理)", "description": "保持 worktree 和分支不变" },
{ "label": "丢弃(需确认)", "description": "删除分支和 worktree,放弃所有改动" }
]
}]
}
选项 1 — Merge:
git checkout main && git pull && git merge {feature-branch}
# 验证测试通过后
bash ${CLAUDE_PLUGIN_ROOT}/scripts/cx-worktree.sh cleanup --feature {slug}
git branch -d {feature-branch}
选项 2 — PR:
git push -u origin {feature-branch}
gh pr create --title "{feature-title}" --body "..."
选项 3 — 保留: 不执行任何操作。
选项 4 — 丢弃:
使用 AskUserQuestion 二次确认后:
bash ${CLAUDE_PLUGIN_ROOT}/scripts/cx-worktree.sh cleanup --feature {slug} --force
git branch -D {feature-branch}
闭环完成后:
summarized配置.json.current_feature 清空merged