cc-devflow 4.1.5 → 4.1.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude/CLAUDE.md +87 -1091
- package/.claude/commands/core/architecture.md +2 -2
- package/.claude/commands/core/guidelines.md +2 -2
- package/.claude/commands/core/roadmap.md +4 -4
- package/.claude/commands/core/style.md +40 -268
- package/.claude/commands/flow/CLAUDE.md +28 -0
- package/.claude/commands/flow/archive.md +2 -2
- package/.claude/commands/flow/checklist.md +9 -251
- package/.claude/commands/flow/clarify.md +9 -127
- package/.claude/commands/flow/constitution.md +1 -1
- package/.claude/commands/flow/context.md +1 -1
- package/.claude/commands/flow/dev.md +19 -395
- package/.claude/commands/flow/ideate.md +13 -13
- package/.claude/commands/flow/init.md +19 -30
- package/.claude/commands/flow/new.md +12 -268
- package/.claude/commands/flow/quality.md +10 -153
- package/.claude/commands/flow/release.md +18 -81
- package/.claude/commands/flow/restart.md +15 -16
- package/.claude/commands/flow/spec.md +14 -164
- package/.claude/commands/flow/status.md +12 -12
- package/.claude/commands/flow/update.md +4 -4
- package/.claude/commands/flow/upgrade.md +6 -6
- package/.claude/commands/flow/verify.md +19 -78
- package/.claude/commands/flow/workspace.md +1 -1
- package/.claude/docs/guides/INIT_TROUBLESHOOTING.md +7 -7
- package/.claude/docs/guides/NEW_TROUBLESHOOTING.md +44 -96
- package/.claude/docs/guides/ROADMAP_TROUBLESHOOTING.md +1 -1
- package/.claude/docs/guides/TASK_COMPLETION_MARKING.md +5 -5
- package/.claude/docs/templates/ATTEMPT_TEMPLATE.md +1 -1
- package/.claude/docs/templates/BACKLOG_TEMPLATE.md +3 -3
- package/.claude/docs/templates/CLARIFICATION_REPORT_TEMPLATE.md +5 -5
- package/.claude/docs/templates/ERROR_LOG_TEMPLATE.md +2 -2
- package/.claude/docs/templates/INIT_FLOW_TEMPLATE.md +3 -3
- package/.claude/docs/templates/NEW_ORCHESTRATION_TEMPLATE.md +33 -64
- package/.claude/docs/templates/RESEARCH_TEMPLATE.md +3 -3
- package/.claude/docs/templates/ROADMAP_DIALOGUE_TEMPLATE.md +2 -2
- package/.claude/docs/templates/ROADMAP_TEMPLATE.md +2 -2
- package/.claude/docs/templates/STYLE_TEMPLATE.md +3 -3
- package/.claude/docs/templates/UI_PROTOTYPE_TEMPLATE.md +8 -9
- package/.claude/guides/workflow-guides/flow-orchestrator.md +31 -265
- package/.claude/hooks/CLAUDE.md +1 -1
- package/.claude/hooks/checklist-gate.js +4 -4
- package/.claude/hooks/inject-agent-context.ts +2 -2
- package/.claude/scripts/calculate-checklist-completion.sh +2 -2
- package/.claude/scripts/check-prerequisites.sh +2 -2
- package/.claude/scripts/checklist-errors.sh +4 -4
- package/.claude/scripts/flow-quality-full.sh +5 -5
- package/.claude/scripts/flow-quality-quick.sh +4 -4
- package/.claude/scripts/flow-workspace-init.sh +2 -2
- package/.claude/scripts/generate-clarification-report.sh +4 -4
- package/.claude/scripts/recover-workflow.sh +70 -73
- package/.claude/scripts/run-quality-gates.sh +1 -1
- package/.claude/scripts/setup-epic.sh +2 -2
- package/.claude/scripts/setup-ralph-loop.sh +2 -2
- package/.claude/scripts/validate-research.sh +1 -1
- package/.claude/scripts/verify-setup.sh +1 -1
- package/.claude/skills/cc-devflow-orchestrator/SKILL.md +88 -108
- package/.claude/skills/workflow/CLAUDE.md +24 -0
- package/.claude/skills/workflow/flow-dev/CLAUDE.md +14 -76
- package/.claude/skills/workflow/flow-dev/SKILL.md +29 -67
- package/.claude/skills/workflow/flow-dev/context.jsonl +4 -8
- package/.claude/skills/workflow/flow-init/SKILL.md +24 -151
- package/.claude/skills/workflow/flow-init/assets/RESEARCH_TEMPLATE.md +1 -1
- package/.claude/skills/workflow/flow-init/context.jsonl +3 -3
- package/.claude/skills/workflow/flow-init/scripts/check-prerequisites.sh +1 -1
- package/.claude/skills/workflow/flow-init/scripts/validate-research.sh +1 -1
- package/.claude/skills/workflow/flow-release/SKILL.md +23 -56
- package/.claude/skills/workflow/flow-release/context.jsonl +5 -7
- package/.claude/skills/workflow/flow-spec/CLAUDE.md +15 -101
- package/.claude/skills/workflow/flow-spec/SKILL.md +15 -518
- package/.claude/skills/workflow/flow-spec/context.jsonl +5 -7
- package/.claude/skills/workflow/flow-verify/CLAUDE.md +10 -0
- package/.claude/skills/workflow/flow-verify/SKILL.md +53 -0
- package/.claude/skills/workflow/flow-verify/context.jsonl +5 -0
- package/.claude/skills/workflow.yaml +72 -267
- package/CHANGELOG.md +31 -0
- package/README.md +91 -69
- package/README.zh-CN.md +90 -67
- package/bin/harness.js +22 -0
- package/docs/commands/README.md +34 -38
- package/docs/commands/README.zh-CN.md +34 -36
- package/docs/commands/core-roadmap.md +2 -2
- package/docs/commands/core-roadmap.zh-CN.md +2 -2
- package/docs/commands/core-style.md +29 -381
- package/docs/commands/core-style.zh-CN.md +29 -381
- package/docs/commands/flow-init.md +10 -10
- package/docs/commands/flow-init.zh-CN.md +11 -11
- package/docs/commands/flow-new.md +25 -260
- package/docs/commands/flow-new.zh-CN.md +26 -257
- package/docs/guides/getting-started.md +16 -15
- package/docs/guides/getting-started.zh-CN.md +10 -12
- package/lib/compiler/__tests__/manifest.test.js +156 -0
- package/lib/compiler/__tests__/parser.test.js +21 -0
- package/lib/compiler/index.js +17 -1
- package/lib/compiler/manifest.js +68 -6
- package/lib/compiler/parser.js +5 -0
- package/lib/harness/CLAUDE.md +21 -0
- package/lib/harness/cli.js +208 -0
- package/lib/harness/index.js +16 -0
- package/lib/harness/operations/dispatch.js +285 -0
- package/lib/harness/operations/init.js +48 -0
- package/lib/harness/operations/janitor.js +74 -0
- package/lib/harness/operations/pack.js +100 -0
- package/lib/harness/operations/plan.js +29 -0
- package/lib/harness/operations/release.js +83 -0
- package/lib/harness/operations/resume.js +44 -0
- package/lib/harness/operations/verify.js +163 -0
- package/lib/harness/planner.js +141 -0
- package/lib/harness/schemas.js +108 -0
- package/lib/harness/store.js +240 -0
- package/package.json +9 -1
|
@@ -28,24 +28,23 @@ usage() {
|
|
|
28
28
|
|
|
29
29
|
选项:
|
|
30
30
|
-h, --help 显示此帮助信息
|
|
31
|
-
--from STAGE 从指定阶段重新开始 (init/prd/epic/
|
|
31
|
+
--from STAGE 从指定阶段重新开始 (init/spec/dev/verify/release;prd/epic/quality/qa 兼容)
|
|
32
32
|
--force 强制恢复,跳过安全检查
|
|
33
33
|
--dry-run 显示恢复计划但不执行
|
|
34
34
|
--verbose 显示详细信息
|
|
35
35
|
|
|
36
36
|
阶段说明:
|
|
37
37
|
init - 初始化阶段
|
|
38
|
-
|
|
39
|
-
epic - Epic规划阶段
|
|
38
|
+
spec - 规格与任务规划阶段
|
|
40
39
|
dev - 开发执行阶段
|
|
41
|
-
|
|
40
|
+
verify - 质量验证阶段
|
|
42
41
|
release - 发布管理阶段
|
|
43
42
|
|
|
44
43
|
示例:
|
|
45
44
|
$0 REQ-123 # 自动检测并恢复
|
|
46
45
|
$0 REQ-123 --from dev # 从开发阶段重新开始
|
|
47
46
|
$0 REQ-123 --dry-run # 预览恢复计划
|
|
48
|
-
$0 REQ-123 --from
|
|
47
|
+
$0 REQ-123 --from spec --force # 强制从规划阶段重新开始
|
|
49
48
|
|
|
50
49
|
EOF
|
|
51
50
|
exit 0
|
|
@@ -127,14 +126,14 @@ detect_workflow_status() {
|
|
|
127
126
|
# 检查需求目录是否存在
|
|
128
127
|
if [[ ! -d "$REQ_DIR" ]]; then
|
|
129
128
|
echo -e "${RED}错误: 需求目录不存在: $REQ_DIR${NC}"
|
|
130
|
-
echo -e "${YELLOW}建议: 使用 /flow
|
|
129
|
+
echo -e "${YELLOW}建议: 使用 /flow:init 初始化需求${NC}"
|
|
131
130
|
exit 1
|
|
132
131
|
fi
|
|
133
132
|
|
|
134
133
|
# 检查状态文件
|
|
135
134
|
if [[ ! -f "$STATUS_FILE" ]]; then
|
|
136
135
|
echo -e "${YELLOW}警告: 状态文件不存在,需求可能未正确初始化${NC}"
|
|
137
|
-
echo -e "${YELLOW}建议: 使用 /flow
|
|
136
|
+
echo -e "${YELLOW}建议: 使用 /flow:init --force 重新初始化${NC}"
|
|
138
137
|
exit 1
|
|
139
138
|
fi
|
|
140
139
|
|
|
@@ -213,29 +212,21 @@ analyze_recovery_strategy() {
|
|
|
213
212
|
if [[ -n "$FROM_STAGE" ]]; then
|
|
214
213
|
echo -e "${YELLOW}用户指定从阶段恢复: $FROM_STAGE${NC}"
|
|
215
214
|
validate_stage "$FROM_STAGE"
|
|
216
|
-
echo "$FROM_STAGE"
|
|
215
|
+
echo "$(normalize_stage "$FROM_STAGE")"
|
|
217
216
|
return 0
|
|
218
217
|
fi
|
|
219
218
|
|
|
220
219
|
# 根据当前阶段智能判断恢复点
|
|
221
220
|
case "$current_phase" in
|
|
222
|
-
initialized|planning)
|
|
223
|
-
echo -e "${CYAN}建议:
|
|
224
|
-
echo "
|
|
221
|
+
initialized|context_packed|planning|planned|spec_in_progress)
|
|
222
|
+
echo -e "${CYAN}建议: 从规格阶段开始${NC}"
|
|
223
|
+
echo "spec"
|
|
225
224
|
;;
|
|
226
|
-
prd_generation_in_progress)
|
|
227
|
-
echo -e "${CYAN}建议: 重新生成 PRD${NC}"
|
|
228
|
-
echo "prd"
|
|
229
|
-
;;
|
|
230
|
-
prd_complete|epic_planning)
|
|
231
|
-
echo -e "${CYAN}建议: 从 Epic 阶段开始${NC}"
|
|
232
|
-
echo "epic"
|
|
233
|
-
;;
|
|
234
|
-
epic_complete)
|
|
225
|
+
prd_generation_in_progress|epic_planning|prd_complete|epic_complete|spec_complete)
|
|
235
226
|
echo -e "${CYAN}建议: 从开发阶段开始${NC}"
|
|
236
227
|
echo "dev"
|
|
237
228
|
;;
|
|
238
|
-
development|dev_complete)
|
|
229
|
+
development|development_in_progress|dev_complete|development_complete)
|
|
239
230
|
# 检查是否有未完成的任务
|
|
240
231
|
if [[ -f "$REQ_DIR/TASKS.md" ]]; then
|
|
241
232
|
# 统计已完成任务 (- [x] 标记)
|
|
@@ -252,16 +243,20 @@ analyze_recovery_strategy() {
|
|
|
252
243
|
echo "dev"
|
|
253
244
|
else
|
|
254
245
|
echo -e "${CYAN}建议: 进入质量验证阶段${NC}"
|
|
255
|
-
echo "
|
|
246
|
+
echo "verify"
|
|
256
247
|
fi
|
|
257
248
|
else
|
|
258
249
|
echo -e "${CYAN}建议: 从开发阶段开始${NC}"
|
|
259
250
|
echo "dev"
|
|
260
251
|
fi
|
|
261
252
|
;;
|
|
262
|
-
quality|
|
|
253
|
+
quality|qa|verification_in_progress)
|
|
263
254
|
echo -e "${CYAN}建议: 从质量验证阶段开始${NC}"
|
|
264
|
-
echo "
|
|
255
|
+
echo "verify"
|
|
256
|
+
;;
|
|
257
|
+
quality_complete|qa_complete|verified)
|
|
258
|
+
echo -e "${CYAN}建议: 从发布阶段开始${NC}"
|
|
259
|
+
echo "release"
|
|
265
260
|
;;
|
|
266
261
|
release|release_complete)
|
|
267
262
|
echo -e "${CYAN}建议: 从发布阶段开始${NC}"
|
|
@@ -273,8 +268,8 @@ analyze_recovery_strategy() {
|
|
|
273
268
|
exit 0
|
|
274
269
|
;;
|
|
275
270
|
*)
|
|
276
|
-
echo -e "${YELLOW}警告: 未知阶段 '$current_phase'
|
|
277
|
-
echo "
|
|
271
|
+
echo -e "${YELLOW}警告: 未知阶段 '$current_phase',从规格阶段开始${NC}"
|
|
272
|
+
echo "spec"
|
|
278
273
|
;;
|
|
279
274
|
esac
|
|
280
275
|
}
|
|
@@ -284,17 +279,33 @@ validate_stage() {
|
|
|
284
279
|
local stage="$1"
|
|
285
280
|
|
|
286
281
|
case "$stage" in
|
|
287
|
-
init|prd|epic|
|
|
282
|
+
init|spec|dev|verify|release|prd|epic|quality|qa)
|
|
288
283
|
return 0
|
|
289
284
|
;;
|
|
290
285
|
*)
|
|
291
286
|
echo -e "${RED}错误: 无效的阶段 '$stage'${NC}"
|
|
292
|
-
echo -e "${YELLOW}有效阶段: init,
|
|
287
|
+
echo -e "${YELLOW}有效阶段: init, spec, dev, verify, release (prd/epic/quality/qa 兼容)${NC}"
|
|
293
288
|
exit 1
|
|
294
289
|
;;
|
|
295
290
|
esac
|
|
296
291
|
}
|
|
297
292
|
|
|
293
|
+
# 兼容历史阶段名称,统一映射到主链阶段
|
|
294
|
+
normalize_stage() {
|
|
295
|
+
local stage="$1"
|
|
296
|
+
case "$stage" in
|
|
297
|
+
prd|epic)
|
|
298
|
+
echo "spec"
|
|
299
|
+
;;
|
|
300
|
+
quality|qa)
|
|
301
|
+
echo "verify"
|
|
302
|
+
;;
|
|
303
|
+
*)
|
|
304
|
+
echo "$stage"
|
|
305
|
+
;;
|
|
306
|
+
esac
|
|
307
|
+
}
|
|
308
|
+
|
|
298
309
|
# ============================================================================
|
|
299
310
|
# 恢复执行
|
|
300
311
|
# ============================================================================
|
|
@@ -315,19 +326,16 @@ generate_recovery_plan() {
|
|
|
315
326
|
local stages=()
|
|
316
327
|
case "$start_stage" in
|
|
317
328
|
init)
|
|
318
|
-
stages=("init" "
|
|
329
|
+
stages=("init" "spec" "dev" "verify" "release")
|
|
319
330
|
;;
|
|
320
|
-
|
|
321
|
-
stages=("
|
|
322
|
-
;;
|
|
323
|
-
epic)
|
|
324
|
-
stages=("epic" "dev" "quality" "release")
|
|
331
|
+
spec)
|
|
332
|
+
stages=("spec" "dev" "verify" "release")
|
|
325
333
|
;;
|
|
326
334
|
dev)
|
|
327
|
-
stages=("dev" "
|
|
335
|
+
stages=("dev" "verify" "release")
|
|
328
336
|
;;
|
|
329
|
-
|
|
330
|
-
stages=("
|
|
337
|
+
verify)
|
|
338
|
+
stages=("verify" "release")
|
|
331
339
|
;;
|
|
332
340
|
release)
|
|
333
341
|
stages=("release")
|
|
@@ -340,22 +348,19 @@ generate_recovery_plan() {
|
|
|
340
348
|
local command=""
|
|
341
349
|
case "$stage" in
|
|
342
350
|
init)
|
|
343
|
-
command="/flow
|
|
344
|
-
;;
|
|
345
|
-
prd)
|
|
346
|
-
command="/flow-prd \"$REQ_ID\""
|
|
351
|
+
command="/flow:init \"$REQ_ID\""
|
|
347
352
|
;;
|
|
348
|
-
|
|
349
|
-
command="/flow
|
|
353
|
+
spec)
|
|
354
|
+
command="/flow:spec \"$REQ_ID\""
|
|
350
355
|
;;
|
|
351
356
|
dev)
|
|
352
|
-
command="/flow
|
|
357
|
+
command="/flow:dev \"$REQ_ID\" --resume"
|
|
353
358
|
;;
|
|
354
|
-
|
|
355
|
-
command="/flow
|
|
359
|
+
verify)
|
|
360
|
+
command="/flow:verify \"$REQ_ID\" --strict"
|
|
356
361
|
;;
|
|
357
362
|
release)
|
|
358
|
-
command="/flow
|
|
363
|
+
command="/flow:release \"$REQ_ID\""
|
|
359
364
|
;;
|
|
360
365
|
esac
|
|
361
366
|
|
|
@@ -387,43 +392,35 @@ execute_recovery() {
|
|
|
387
392
|
fi
|
|
388
393
|
|
|
389
394
|
# 根据起始阶段执行命令
|
|
390
|
-
# 注意: 这里只是展示命令,实际执行由用户手动调用或使用 /flow
|
|
395
|
+
# 注意: 这里只是展示命令,实际执行由用户手动调用或使用 /flow:restart
|
|
391
396
|
echo -e "${CYAN}请手动执行以下命令以恢复工作流:${NC}"
|
|
392
397
|
echo ""
|
|
393
398
|
|
|
394
399
|
case "$start_stage" in
|
|
395
400
|
init)
|
|
396
|
-
echo "/flow
|
|
397
|
-
echo "/flow
|
|
398
|
-
echo "/flow
|
|
399
|
-
echo "/flow
|
|
400
|
-
echo "/flow
|
|
401
|
-
echo "/flow-release \"$REQ_ID\""
|
|
401
|
+
echo "/flow:init \"$REQ_ID\""
|
|
402
|
+
echo "/flow:spec \"$REQ_ID\""
|
|
403
|
+
echo "/flow:dev \"$REQ_ID\""
|
|
404
|
+
echo "/flow:verify \"$REQ_ID\" --strict"
|
|
405
|
+
echo "/flow:release \"$REQ_ID\""
|
|
402
406
|
;;
|
|
403
|
-
|
|
404
|
-
echo "/flow
|
|
405
|
-
echo "/flow
|
|
406
|
-
echo "/flow
|
|
407
|
-
echo "/flow
|
|
408
|
-
echo "/flow-release \"$REQ_ID\""
|
|
409
|
-
;;
|
|
410
|
-
epic)
|
|
411
|
-
echo "/flow-epic \"$REQ_ID\""
|
|
412
|
-
echo "/flow-dev \"$REQ_ID\""
|
|
413
|
-
echo "/flow-quality \"$REQ_ID\""
|
|
414
|
-
echo "/flow-release \"$REQ_ID\""
|
|
407
|
+
spec)
|
|
408
|
+
echo "/flow:spec \"$REQ_ID\""
|
|
409
|
+
echo "/flow:dev \"$REQ_ID\""
|
|
410
|
+
echo "/flow:verify \"$REQ_ID\" --strict"
|
|
411
|
+
echo "/flow:release \"$REQ_ID\""
|
|
415
412
|
;;
|
|
416
413
|
dev)
|
|
417
|
-
echo "/flow
|
|
418
|
-
echo "/flow
|
|
419
|
-
echo "/flow
|
|
414
|
+
echo "/flow:dev \"$REQ_ID\" --resume"
|
|
415
|
+
echo "/flow:verify \"$REQ_ID\" --strict"
|
|
416
|
+
echo "/flow:release \"$REQ_ID\""
|
|
420
417
|
;;
|
|
421
|
-
|
|
422
|
-
echo "/flow
|
|
423
|
-
echo "/flow
|
|
418
|
+
verify)
|
|
419
|
+
echo "/flow:verify \"$REQ_ID\" --strict"
|
|
420
|
+
echo "/flow:release \"$REQ_ID\""
|
|
424
421
|
;;
|
|
425
422
|
release)
|
|
426
|
-
echo "/flow
|
|
423
|
+
echo "/flow:release \"$REQ_ID\""
|
|
427
424
|
;;
|
|
428
425
|
esac
|
|
429
426
|
|
|
@@ -25,7 +25,7 @@ Usage: run-quality-gates.sh <phase> [--json] [--verbose]
|
|
|
25
25
|
Execute quality gate verification commands for a phase.
|
|
26
26
|
|
|
27
27
|
Arguments:
|
|
28
|
-
phase Phase name (flow-dev, flow-review, flow-quality, flow-
|
|
28
|
+
phase Phase name (flow-dev, flow-review, flow-quality, flow-release)
|
|
29
29
|
|
|
30
30
|
Options:
|
|
31
31
|
--json Output results as JSON
|
|
@@ -78,7 +78,7 @@ validate_req_id "$REQ_ID" || exit 1
|
|
|
78
78
|
# Ensure the requirement directory exists
|
|
79
79
|
if [[ ! -d "$REQ_DIR" ]]; then
|
|
80
80
|
echo "ERROR: Requirement directory not found: $REQ_DIR" >&2
|
|
81
|
-
echo "Run /flow
|
|
81
|
+
echo "Run /flow:init first to create the requirement structure." >&2
|
|
82
82
|
exit 1
|
|
83
83
|
fi
|
|
84
84
|
|
|
@@ -170,4 +170,4 @@ else
|
|
|
170
170
|
echo "PRD_FILE: $PRD_FILE"
|
|
171
171
|
echo "EPIC_FILE: $EPIC_FILE"
|
|
172
172
|
echo "TASKS_FILE: $TASKS_FILE"
|
|
173
|
-
fi
|
|
173
|
+
fi
|
|
@@ -91,14 +91,14 @@ fi
|
|
|
91
91
|
REQ_DIR="devflow/requirements/${REQ_ID}"
|
|
92
92
|
if [[ ! -d "$REQ_DIR" ]]; then
|
|
93
93
|
echo "❌ Error: Requirement directory not found: $REQ_DIR" >&2
|
|
94
|
-
echo " Run /flow
|
|
94
|
+
echo " Run /flow:init first to create the requirement structure" >&2
|
|
95
95
|
exit 1
|
|
96
96
|
fi
|
|
97
97
|
|
|
98
98
|
# Check if TASKS.md exists
|
|
99
99
|
if [[ ! -f "${REQ_DIR}/TASKS.md" ]]; then
|
|
100
100
|
echo "❌ Error: TASKS.md not found in $REQ_DIR" >&2
|
|
101
|
-
echo " Run /flow
|
|
101
|
+
echo " Run /flow:spec first to generate tasks" >&2
|
|
102
102
|
exit 1
|
|
103
103
|
fi
|
|
104
104
|
|
|
@@ -303,7 +303,7 @@ main() {
|
|
|
303
303
|
echo "════════════════════════════════════════════════════════════════════════"
|
|
304
304
|
if [[ $total_errors -eq 0 ]]; then
|
|
305
305
|
echo "✅ ALL VALIDATIONS PASSED"
|
|
306
|
-
echo "research.md is ready for /flow
|
|
306
|
+
echo "research.md is ready for /flow:spec"
|
|
307
307
|
echo "════════════════════════════════════════════════════════════════════════"
|
|
308
308
|
return 0
|
|
309
309
|
else
|
|
@@ -31,7 +31,7 @@ require_file() {
|
|
|
31
31
|
require_dir "$CLAUDE_DIR/commands"
|
|
32
32
|
require_dir "$CLAUDE_DIR/skills"
|
|
33
33
|
require_dir "$CLAUDE_DIR/scripts"
|
|
34
|
-
require_file "$CLAUDE_DIR/commands/flow
|
|
34
|
+
require_file "$CLAUDE_DIR/commands/flow/new.md"
|
|
35
35
|
require_file "$CLAUDE_DIR/skills/cc-devflow-orchestrator/SKILL.md"
|
|
36
36
|
|
|
37
37
|
echo "cc-devflow setup OK."
|
|
@@ -6,159 +6,139 @@ description: CC-DevFlow workflow router and agent recommender. Use when starting
|
|
|
6
6
|
# CC-DevFlow Orchestrator
|
|
7
7
|
|
|
8
8
|
## Purpose
|
|
9
|
-
Guide users to the correct
|
|
9
|
+
Guide users to the correct command/skill without duplicating detailed implementation standards.
|
|
10
10
|
|
|
11
11
|
## Workflow Map
|
|
12
12
|
|
|
13
|
-
###
|
|
13
|
+
### Project-Level (run once per project)
|
|
14
14
|
|
|
15
|
-
```
|
|
16
|
-
/core:roadmap
|
|
17
|
-
/core:architecture → ARCHITECTURE.md
|
|
18
|
-
/core:guidelines
|
|
19
|
-
/core:style
|
|
15
|
+
```text
|
|
16
|
+
/core:roadmap → ROADMAP.md + BACKLOG.md
|
|
17
|
+
/core:architecture → ARCHITECTURE.md
|
|
18
|
+
/core:guidelines → frontend/backend guidelines
|
|
19
|
+
/core:style → STYLE.md
|
|
20
20
|
```
|
|
21
21
|
|
|
22
|
-
###
|
|
22
|
+
### Requirement-Level Canonical Mainline (v6)
|
|
23
23
|
|
|
24
|
-
```
|
|
25
|
-
/flow:init
|
|
26
|
-
|
|
27
|
-
/flow:clarify → clarifications/*.md (11 维度歧义扫描, 可选)
|
|
24
|
+
```text
|
|
25
|
+
/flow:init → harness:init + harness:pack
|
|
26
|
+
→ context-package.md + harness-state.json
|
|
28
27
|
↓
|
|
29
|
-
/flow:spec
|
|
30
|
-
|
|
31
|
-
- Full: PRD → Tech+UI (并行) → Epic
|
|
32
|
-
- Quick: PRD → Epic (--skip-tech --skip-ui)
|
|
33
|
-
- Backend: PRD → Tech → Epic (--skip-ui)
|
|
34
|
-
- Frontend: PRD → UI → Epic (--skip-tech)
|
|
28
|
+
/flow:spec → harness:plan
|
|
29
|
+
→ task-manifest.json
|
|
35
30
|
↓
|
|
36
|
-
/flow:dev
|
|
31
|
+
/flow:dev → harness:dispatch / harness:resume
|
|
32
|
+
→ runtime events + checkpoints + manifest status
|
|
37
33
|
↓
|
|
38
|
-
/flow:
|
|
34
|
+
/flow:verify → harness:verify
|
|
35
|
+
→ report-card.json (quick/strict gates)
|
|
39
36
|
↓
|
|
40
|
-
/flow:release →
|
|
41
|
-
|
|
42
|
-
/flow:verify → consistency check (任意阶段可调用)
|
|
43
|
-
```
|
|
44
|
-
|
|
45
|
-
### 🚀 简化流程
|
|
46
|
-
|
|
37
|
+
/flow:release → harness:release + harness:janitor
|
|
38
|
+
→ RELEASE_NOTE.md + released state
|
|
47
39
|
```
|
|
48
|
-
【精简流程】(适合小需求, 3 步)
|
|
49
|
-
/flow:init --quick → /flow:spec --skip-tech --skip-ui → /flow:dev → /flow:release
|
|
50
40
|
|
|
51
|
-
|
|
52
|
-
/flow:init → /flow:spec → /flow:dev → /flow:quality → /flow:release
|
|
41
|
+
### Bug Workflow
|
|
53
42
|
|
|
54
|
-
|
|
55
|
-
/flow:
|
|
43
|
+
```text
|
|
44
|
+
/flow:fix "BUG-123|描述" → 系统化调试与修复
|
|
56
45
|
```
|
|
57
46
|
|
|
58
|
-
###
|
|
47
|
+
### Deprecated Migrations (keep for compatibility)
|
|
59
48
|
|
|
49
|
+
```text
|
|
50
|
+
/flow:new → /flow:init → /flow:spec → /flow:dev → /flow:verify → /flow:release
|
|
51
|
+
/flow:clarify → merged into /flow:spec
|
|
52
|
+
/flow:checklist → merged into /flow:verify --strict
|
|
53
|
+
/flow:quality → merged into /flow:verify
|
|
60
54
|
```
|
|
61
|
-
/flow:fix "BUG-123|描述" → 系统化调试 (4阶段: Root Cause → Pattern → Hypothesis → TDD Fix)
|
|
62
|
-
```
|
|
63
|
-
|
|
64
|
-
**说明**:
|
|
65
|
-
- `/flow:spec` 是统一规格命令,合并 PRD/Tech/UI/Epic 为单一命令
|
|
66
|
-
- `/flow:spec` 内部并行执行 Tech + UI,减少 ~35% 设计阶段时间
|
|
67
|
-
- `/flow:dev` 默认 Autonomous 模式(自动重试),使用 `--manual` 退出到 Manual 模式
|
|
68
55
|
|
|
69
|
-
##
|
|
56
|
+
## Routing Guide
|
|
70
57
|
|
|
71
|
-
###
|
|
72
|
-
-
|
|
73
|
-
-
|
|
74
|
-
- **Modes**: Full (default), Quick (--skip-tech --skip-ui), Backend (--skip-ui), Frontend (--skip-tech)
|
|
58
|
+
### Requirement kickoff
|
|
59
|
+
- Recommend: `/flow:init "REQ-123|Title|URLs?"`
|
|
60
|
+
- Then: `/flow:spec "REQ-123"`
|
|
75
61
|
|
|
76
|
-
###
|
|
77
|
-
-
|
|
78
|
-
-
|
|
62
|
+
### Planning/specification questions
|
|
63
|
+
- Recommend: `/flow:spec`
|
|
64
|
+
- Notes: this is the unified planning stage for executable task-manifest generation.
|
|
79
65
|
|
|
80
|
-
###
|
|
81
|
-
-
|
|
82
|
-
-
|
|
66
|
+
### Development execution / interrupted execution
|
|
67
|
+
- Recommend: `/flow:dev "REQ-123"`
|
|
68
|
+
- If interrupted/failed: `/flow:dev "REQ-123" --resume`
|
|
83
69
|
|
|
84
|
-
###
|
|
85
|
-
-
|
|
86
|
-
-
|
|
70
|
+
### QA/security/release readiness
|
|
71
|
+
- Recommend: `/flow:verify "REQ-123"`
|
|
72
|
+
- Strict gate: `/flow:verify "REQ-123" --strict`
|
|
87
73
|
|
|
88
|
-
###
|
|
89
|
-
-
|
|
90
|
-
-
|
|
74
|
+
### Release
|
|
75
|
+
- Recommend: `/flow:release "REQ-123"`
|
|
76
|
+
- Release is blocked when report-card overall is fail.
|
|
91
77
|
|
|
92
|
-
###
|
|
93
|
-
-
|
|
94
|
-
-
|
|
78
|
+
### Code review requests
|
|
79
|
+
- Recommend: `/flow:verify "REQ-123" --strict`
|
|
80
|
+
- Optional deep review: `/util:code-review "<diff>"`
|
|
95
81
|
|
|
96
82
|
## Phase Gates (Quick Reference)
|
|
97
83
|
|
|
98
84
|
### Entry Gates
|
|
99
|
-
-
|
|
100
|
-
-
|
|
101
|
-
-
|
|
102
|
-
-
|
|
103
|
-
-
|
|
104
|
-
- **flow:release Entry**: quality_complete == true
|
|
85
|
+
- `flow:init`: repository and requirement id are valid.
|
|
86
|
+
- `flow:spec`: `context-package.md` and `harness-state.json` exist.
|
|
87
|
+
- `flow:dev`: `task-manifest.json` exists and is schema-valid.
|
|
88
|
+
- `flow:verify`: task dispatch completed or at least one dispatch/resume run exists.
|
|
89
|
+
- `flow:release`: `report-card.json.overall == pass`.
|
|
105
90
|
|
|
106
91
|
### Exit Gates
|
|
107
|
-
-
|
|
108
|
-
-
|
|
109
|
-
-
|
|
110
|
-
-
|
|
111
|
-
-
|
|
92
|
+
- `flow:init`: requirement context packaged.
|
|
93
|
+
- `flow:spec`: task-manifest generated.
|
|
94
|
+
- `flow:dev`: task statuses updated with runtime checkpoints/events.
|
|
95
|
+
- `flow:verify`: report-card emitted (quick/strict/review sections).
|
|
96
|
+
- `flow:release`: release note generated and harness state marked released.
|
|
112
97
|
|
|
113
|
-
## State
|
|
98
|
+
## State → Recommended Command
|
|
114
99
|
|
|
115
100
|
```yaml
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
→ Alternative: /flow:clarify (optional)
|
|
101
|
+
no_requirement_context:
|
|
102
|
+
recommend: /flow:init
|
|
119
103
|
|
|
120
|
-
|
|
121
|
-
|
|
104
|
+
initialized_or_context_packed:
|
|
105
|
+
recommend: /flow:spec
|
|
122
106
|
|
|
123
|
-
|
|
124
|
-
|
|
107
|
+
manifest_exists_with_pending_or_failed:
|
|
108
|
+
recommend: /flow:dev
|
|
109
|
+
alternative: /flow:dev --resume
|
|
125
110
|
|
|
126
|
-
|
|
127
|
-
|
|
111
|
+
manifest_all_passed_without_report_card:
|
|
112
|
+
recommend: /flow:verify --strict
|
|
128
113
|
|
|
129
|
-
|
|
130
|
-
|
|
114
|
+
report_card_fail:
|
|
115
|
+
recommend: /flow:dev --resume
|
|
116
|
+
then: /flow:verify --strict
|
|
131
117
|
|
|
132
|
-
|
|
133
|
-
|
|
118
|
+
report_card_pass:
|
|
119
|
+
recommend: /flow:release
|
|
120
|
+
|
|
121
|
+
released:
|
|
122
|
+
recommend: /flow:archive (optional)
|
|
134
123
|
```
|
|
135
124
|
|
|
136
125
|
## Auxiliary Commands
|
|
137
126
|
|
|
138
|
-
###
|
|
139
|
-
- `/flow:status` -
|
|
140
|
-
- `/flow:update "REQ-123" "T012"` -
|
|
141
|
-
- `/flow:restart "REQ-123" --from=
|
|
142
|
-
|
|
143
|
-
### Upgrade and Analysis
|
|
144
|
-
- `/flow:upgrade "REQ-123" --analyze` - PRD version upgrade impact analysis
|
|
145
|
-
- `/flow:constitution` - Constitution management
|
|
146
|
-
- `/flow:verify "REQ-123"` - Comprehensive consistency verification
|
|
147
|
-
|
|
148
|
-
### Bug Fix
|
|
149
|
-
- `/flow:fix "BUG-123|描述"` - 系统化 BUG 修复
|
|
150
|
-
- `/util:problem-analyzer "<issue>"` - Problem diagnosis
|
|
127
|
+
### Progress and recovery
|
|
128
|
+
- `/flow:status` - query requirement progress
|
|
129
|
+
- `/flow:update "REQ-123" "T012"` - update task progress
|
|
130
|
+
- `/flow:restart "REQ-123" --from=dev` - recover interrupted workflow state
|
|
151
131
|
|
|
152
|
-
###
|
|
153
|
-
- `/flow:
|
|
154
|
-
- `/
|
|
132
|
+
### Upgrade and governance
|
|
133
|
+
- `/flow:upgrade "REQ-123" --analyze` - PRD version impact analysis
|
|
134
|
+
- `/flow:constitution` - constitution governance
|
|
135
|
+
- `/flow:verify "REQ-123"` - consistency and quality verification
|
|
155
136
|
|
|
156
137
|
## Design Principle
|
|
157
138
|
|
|
158
|
-
|
|
159
|
-
-
|
|
160
|
-
-
|
|
161
|
-
-
|
|
162
|
-
- ✅ Links to detailed documentation
|
|
139
|
+
This skill only does routing:
|
|
140
|
+
- Which command to run next
|
|
141
|
+
- Which gate blocks progress
|
|
142
|
+
- Which migration path applies for deprecated commands
|
|
163
143
|
|
|
164
|
-
|
|
144
|
+
Detailed quality standards stay in command files and workflow skills.
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
# workflow/
|
|
2
|
+
> L2 | 父级: /Users/dimon/001Area/80-CodeWorld/002-devflow/cc-devflow/.claude/CLAUDE.md
|
|
3
|
+
|
|
4
|
+
成员清单
|
|
5
|
+
flow-init/SKILL.md: 需求初始化入口,调用 harness:init + harness:pack。
|
|
6
|
+
flow-init/context.jsonl: flow-init 的上下文注入定义。
|
|
7
|
+
flow-spec/SKILL.md: 计划生成入口,调用 harness:plan 产出 task-manifest。
|
|
8
|
+
flow-spec/context.jsonl: flow-spec 的上下文注入定义。
|
|
9
|
+
flow-spec/team-config.json: 旧 Team 配置资产(兼容保留,当前主链不依赖)。
|
|
10
|
+
flow-dev/SKILL.md: 执行入口,调用 harness:dispatch/resume 并写 checkpoint/events。
|
|
11
|
+
flow-dev/context.jsonl: flow-dev 的上下文注入定义。
|
|
12
|
+
flow-dev/dev-implementer.jsonl: 旧 dev-implementer 上下文(兼容保留)。
|
|
13
|
+
flow-verify/SKILL.md: 质量门禁入口,调用 harness:verify 输出 report-card。
|
|
14
|
+
flow-verify/context.jsonl: flow-verify 的上下文注入定义。
|
|
15
|
+
flow-release/SKILL.md: 发布入口,调用 harness:release + harness:janitor。
|
|
16
|
+
flow-release/context.jsonl: flow-release 的上下文注入定义。
|
|
17
|
+
flow-quality/SKILL.md: 旧质量流程技能(迁移过渡保留)。
|
|
18
|
+
flow-quality/context.jsonl: 旧质量流程上下文(迁移过渡保留)。
|
|
19
|
+
flow-fix/SKILL.md: Bug 修复流程技能。
|
|
20
|
+
flow-fix/context.jsonl: flow-fix 的上下文注入定义。
|
|
21
|
+
|
|
22
|
+
法则: 成员完整·一行一文件·父级链接·技术词前置
|
|
23
|
+
|
|
24
|
+
[PROTOCOL]: 变更时更新此头部,然后检查 CLAUDE.md
|