From superpowers-zh
Spawns a focused sub-agent to review code changes before merging or after task completion, comparing diff between two git SHAs.
How this skill is triggered — by the user, by Claude, or both
Slash command
/superpowers-zh:requesting-code-reviewThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
派遣代码审查子代理,在问题扩散之前发现它们。审查者获得的是精心组织的评估上下文——绝不是你的会话历史。这样可以让审查者专注于工作成果而非你的思考过程,同时保留你自己的上下文以便继续工作。
派遣代码审查子代理,在问题扩散之前发现它们。审查者获得的是精心组织的评估上下文——绝不是你的会话历史。这样可以让审查者专注于工作成果而非你的思考过程,同时保留你自己的上下文以便继续工作。
核心原则: 早审查,勤审查。
必须审查:
可选但有价值:
1. 获取 git SHA:
BASE_SHA=$(git rev-parse HEAD~1) # 或 origin/main
HEAD_SHA=$(git rev-parse HEAD)
2. 派遣代码审查子代理:
使用 Task 工具,指定 general-purpose 类型,填写 code-reviewer.md 中的模板
占位符说明:
{DESCRIPTION} - 你刚完成的内容简要说明{PLAN_OR_REQUIREMENTS} - 预期功能{BASE_SHA} - 起始提交{HEAD_SHA} - 结束提交3. 处理反馈:
[刚完成任务 2:添加验证功能]
你:让我在继续之前请求代码审查。
BASE_SHA=$(git log --oneline | grep "Task 1" | head -1 | awk '{print $1}')
HEAD_SHA=$(git rev-parse HEAD)
[派遣代码审查子代理]
DESCRIPTION: 添加了 verifyIndex() 和 repairIndex(),支持 4 种问题类型
PLAN_OR_REQUIREMENTS: docs/superpowers/plans/deployment-plan.md 中的任务 2
BASE_SHA: a7981ec
HEAD_SHA: 3df7661
[子代理返回]:
优点:架构清晰,测试真实
问题:
Important:缺少进度指示器
Minor:报告间隔使用了魔法数字 (100)
评估:可以继续
你:[修复进度指示器]
[继续任务 3]
子代理驱动开发:
执行计划:
临时开发:
绝不要:
如果审查者有误:
参见模板:requesting-code-review/code-reviewer.md
npx claudepluginhub jnmetacode/superpowers-zh --plugin superpowers-zhRequests code review by dispatching a subagent with git diff context. Use after completing tasks, major features, or before merging to catch issues early.
Requests code review using a subagent with git diff context. Automates review after tasks, major features, or before merging to catch issues early.
Requests code review via subagent to catch issues before merging. Integrates with git workflows and subagent-driven development.