wrap-up

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Wrap-Up Ritual

收尾流程

End your coding session with intention.
有意识地结束你的编码会话。

Trigger

触发条件

Use when ending a session, saying "wrap up", "done for now", or before closing the editor.
当准备结束会话、说“wrap up”“done for now”,或关闭编辑器之前时使用。

Workflow

工作流

  1. Changes Audit — What files were modified? Anything uncommitted? TODOs left in code?
  2. Quality Check — Run lint, typecheck, and tests. All passing? Any warnings?
  3. Learning Capture — What mistakes were made? What patterns worked well? Format as
    [LEARN] Category: Rule
  4. Next Session Context — What's the next logical task? Any blockers? Context to preserve?
  5. Summary — One paragraph: what was accomplished, current state, what's next.
  1. 变更审计——修改了哪些文件?是否有未提交的更改?代码中是否遗留 TODO?
  2. 质量检查——运行 lint、typecheck 和 tests。是否全部通过?是否有警告?
  3. 经验沉淀——犯了哪些错误?哪些做法效果良好?按
    [LEARN] Category: Rule
    的格式记录
  4. 下次会话上下文——下一项合理的任务是什么?是否存在阻碍?需要保留哪些上下文?
  5. 摘要——用一个段落说明:完成了什么、当前状态如何、下一步是什么。

Commands

命令

bash
git status
git diff --stat

npm run lint 2>&1 | head -20
npm run typecheck 2>&1 | head -20
npm test -- --changed --passWithNoTests
bash
git status
git diff --stat

npm run lint 2>&1 | head -20
npm run typecheck 2>&1 | head -20
npm test -- --changed --passWithNoTests

Learning Categories

经验分类

Navigation, Editing, Testing, Git, Quality, Context, Architecture, Performance
导航、编辑、测试、Git、质量、上下文、架构、性能

Guardrails

约束条件

  • Do not skip any checklist step.
  • If tests are failing, flag before ending session.
  • If uncommitted changes exist, ask whether to commit or stash.
  • 不要跳过任何检查清单步骤。
  • 如果测试失败,结束会话前必须标记出来。
  • 如果存在未提交的更改,询问用户是提交还是 stash。

Output

输出

  • Modified file list with uncommitted changes highlighted
  • Quality gate results
  • Captured learnings (if any)
  • One-paragraph session summary
  • Next session resume context
After completing checklist, ask: "Ready to end session?"
  • 修改文件列表,并突出显示未提交的更改
  • 质量门禁结果
  • 已沉淀的经验(如有)
  • 一段式的会话摘要
  • 下次会话的恢复上下文
完成检查清单后,询问:“准备好结束会话了吗?”