dev-checkpoint
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseCheckpoint Current Session
为当前会话创建检查点
Review the current session and create a continuation prompt for the next session.
回顾当前会话,为下一次会话生成续期提示词。
SAVE-ONLY MODE
仅保存模式
This skill analyzes and saves. It does NOT fix, investigate, or implement anything.
- Do NOT investigate bugs or errors mentioned during the session
- Do NOT start implementing fixes or next steps
- Do NOT move to the next phase or task
- If the user mentions bugs during confirmation (Step 6), note them in or
<blockers>but do NOT attempt to fix them<notes>
该技能仅进行分析与保存操作。不进行修复、调查或实现任何内容。
- 请勿调查会话中提到的漏洞或错误
- 请勿开始实施修复措施或下一步任务
- 请勿进入下一阶段或任务
- 如果用户在确认环节(步骤6)中提到漏洞,请将其记录在或
<blockers>中,但不要尝试修复<notes>
Step 0: Determine Project Root
步骤0:确定项目根目录
Before proceeding, determine the project root directory:
- If this is a git repository, use:
git rev-parse --show-toplevel - If not a git repository, use the initial working directory from the session context (shown in the environment info at session start)
Store this as and use it for all path references throughout this skill.
$PROJECT_ROOT.dev/在开始操作前,先确定项目根目录:
- 如果是Git仓库,使用命令:
git rev-parse --show-toplevel - 如果不是Git仓库,使用会话上下文里的初始工作目录(会话开始时的环境信息中会显示)
将该路径保存为,并在本技能的所有路径引用中使用该变量。
$PROJECT_ROOT.dev/Step 1: Identify the Active Feature
步骤1:识别当前功能
First, check if a directory exists. If it does not exist, ask the user to specify the feature name and create the directory before proceeding.
$PROJECT_ROOT/.dev/$PROJECT_ROOT/.dev/<feature-name>/If exists, find all available features:
$PROJECT_ROOT/.dev/bash
find "$PROJECT_ROOT/.dev" -maxdepth 1 -type d ! -name .devIf an argument was provided ():
$ARGUMENTS- Filter the feature list to those whose name contains the argument (case-insensitive match)
- If exactly one match: use that feature
- If multiple matches: ask which of the matching features to checkpoint
- If no matches: inform the user that no features match "$ARGUMENTS" and list all available features
If no argument was provided:
- If multiple features exist: ask "Which feature would you like to checkpoint?" and list the available features
- If only one feature exists: use that one
- If no features exist: ask the user to specify the feature name
The checkpoint will be saved to .
$PROJECT_ROOT/.dev/<feature-name>/checkpoint.md首先检查目录是否存在。如果不存在,请让用户指定功能名称,并先创建目录,再继续操作。
$PROJECT_ROOT/.dev/$PROJECT_ROOT/.dev/<feature-name>/如果目录存在,查找所有可用的功能:
$PROJECT_ROOT/.dev/bash
find "$PROJECT_ROOT/.dev" -maxdepth 1 -type d ! -name .dev如果提供了参数():
$ARGUMENTS- 过滤功能列表,仅保留名称包含该参数的功能(不区分大小写)
- 如果恰好有一个匹配项:使用该功能
- 如果有多个匹配项:询问用户要为哪个匹配的功能创建检查点
- 如果没有匹配项:告知用户没有功能与"$ARGUMENTS"匹配,并列出所有可用功能
如果未提供参数:
- 如果存在多个功能:询问用户“你想要为哪个功能创建检查点?”并列出所有可用功能
- 如果只有一个功能:直接使用该功能
- 如果没有功能:请用户指定功能名称
检查点将保存至。
$PROJECT_ROOT/.dev/<feature-name>/checkpoint.mdStep 2: Analyze Session with Agent
步骤2:通过Agent分析会话
Launch the checkpoint-analyzer agent to scan PRD files and the current session:
"Analyze the PRD files in $PROJECT_ROOT/.dev/<feature-name>/ and the current session.
Find: completed items (⬜ → ✅), pending items, decisions made, blockers encountered.
Determine current phase and next step."Use and .
subagent_type=dev-workflow:checkpoint-analyzermodel=haiku启动checkpoint-analyzer agent来扫描PRD文件和当前会话:
"Analyze the PRD files in $PROJECT_ROOT/.dev/<feature-name>/ and the current session.
Find: completed items (⬜ → ✅), pending items, decisions made, blockers encountered.
Determine current phase and next step."使用和。
subagent_type=dev-workflow:checkpoint-analyzermodel=haikuStep 3: Review Agent Findings
步骤3:审核Agent的分析结果
After the agent returns:
- Verify accuracy — Check that completed/pending items match what happened
- Add missing context — Include any decisions or blockers the agent missed
Agent返回结果后:
- 验证准确性 — 确认已完成/待完成项与实际情况一致
- 补充缺失上下文 — 添加Agent遗漏的决策或障碍信息
Step 4: Update PRD Status Markers (REQUIRED)
步骤4:更新PRD状态标记(必填)
For each PRD file in :
.dev/<feature-name>/- Read the file
- Change to
⬜for completed items; update "Status" fields✅ - Save changes
Track what was updated (file + markers changed) — reported in Step 9.
If nothing was completed, state: "No PRD updates needed."
针对下的每个PRD文件:
.dev/<feature-name>/- 读取文件内容
- 将已完成项的改为
⬜;更新“状态”字段✅ - 保存更改
记录所有更新内容(文件+修改的标记)—— 将在步骤9中汇报。
如果没有完成任何内容,请说明:“无需更新PRD。”
Step 5: Capture Git State
步骤5:捕获Git状态
If git repo, run , , and . Store for checkpoint frontmatter.
git branch --show-currentgit log --oneline -1git status --shortIf not a git repo, skip and omit , , from frontmatter.
branchlast_commituncommitted_changes如果是Git仓库,运行、和命令。将结果保存为检查点的前置信息。
git branch --show-currentgit log --oneline -1git status --short如果不是Git仓库,跳过此步骤,并在前置信息中省略、、字段。
branchlast_commituncommitted_changesStep 6: Confirm Session Context
步骤6:确认会话上下文
Present the agent's findings (decisions, blockers, notes) and ask: "I captured these from our session—correct me if I missed anything or got something wrong."
If a category is empty, omit it.
STOP. Wait for explicit confirmation before proceeding to Step 7. If the user mentions new bugs or issues during this step, add them to the checkpoint notes — do NOT investigate or fix them.
展示Agent的分析结果(决策、障碍、备注),并询问用户:“我已从会话中捕获了以下内容——如果有遗漏或错误,请纠正我。”
如果某一分类为空,则省略该分类。
暂停操作。在进入步骤7前等待用户的明确确认。如果用户在此步骤中提到新的漏洞或问题,请将其添加到检查点备注中——不要调查或修复。
Step 7: Generate Continuation Prompt
步骤7:生成续期提示词
Rules:
- Always include ,
<context>,<current_state>,<next_action>. Omit<key_files>,<decisions>,<blockers>if empty.<notes> - No absolute paths with usernames → use relative paths. No secrets/credentials → use placeholders.
Create a continuation prompt following the template in checkpoint-template.md.
规则:
- 必须包含、
<context>、<current_state>、<next_action>字段。如果<key_files>、<decisions>、<blockers>为空,则省略。<notes> - 请勿包含带用户名的绝对路径 → 使用相对路径。请勿包含密钥/凭证 → 使用占位符。
按照checkpoint-template.md中的模板生成续期提示词。
Step 8: Save Checkpoint
步骤8:保存检查点
Write the continuation prompt to . Create the file if it doesn't exist, or overwrite it completely if it does.
$PROJECT_ROOT/.dev/<feature-name>/checkpoint.md将续期提示词写入。如果文件不存在则创建,如果已存在则完全覆盖。
$PROJECT_ROOT/.dev/<feature-name>/checkpoint.mdStep 9: Summary
步骤9:总结
Report:
- Which feature was checkpointed
- PRD updates made (list each file and what was changed, or state "No updates needed")
- What the next steps are
- Confirm the checkpoint location
汇报以下内容:
- 为哪个功能创建了检查点
- PRD更新内容(列出每个修改的文件及更改内容,或说明“无需更新”)
- 下一步操作
- 确认检查点的存储位置