all-for-claudecode 2.2.1 → 2.3.0
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-plugin/marketplace.json +2 -2
- package/.claude-plugin/plugin.json +1 -1
- package/MIGRATION.md +24 -0
- package/README.md +4 -3
- package/agents/afc-architect.md +5 -0
- package/agents/afc-security.md +6 -0
- package/commands/analyze.md +53 -75
- package/commands/auto.md +25 -9
- package/commands/doctor.md +16 -2
- package/commands/implement.md +1 -1
- package/commands/init.md +3 -2
- package/commands/launch.md +1 -1
- package/commands/plan.md +4 -4
- package/commands/resume.md +3 -1
- package/commands/review.md +1 -1
- package/commands/spec.md +1 -1
- package/commands/tasks.md +2 -2
- package/commands/validate.md +125 -0
- package/docs/phase-gate-protocol.md +1 -1
- package/package.json +1 -1
- package/scripts/afc-consistency-check.sh +1 -1
- package/scripts/afc-task-completed-gate.sh +7 -1
|
@@ -6,14 +6,14 @@
|
|
|
6
6
|
},
|
|
7
7
|
"metadata": {
|
|
8
8
|
"description": "Automated pipeline for Claude Code — spec → plan → implement → review → clean",
|
|
9
|
-
"version": "2.
|
|
9
|
+
"version": "2.3.0"
|
|
10
10
|
},
|
|
11
11
|
"plugins": [
|
|
12
12
|
{
|
|
13
13
|
"name": "afc",
|
|
14
14
|
"source": "./",
|
|
15
15
|
"description": "Automated pipeline for Claude Code. Automates the full development cycle: spec → plan → implement → review → clean.",
|
|
16
|
-
"version": "2.
|
|
16
|
+
"version": "2.3.0",
|
|
17
17
|
"category": "automation",
|
|
18
18
|
"tags": ["pipeline", "automation", "spec", "plan", "implement", "review", "critic-loop"]
|
|
19
19
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "afc",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.3.0",
|
|
4
4
|
"description": "Automated pipeline for Claude Code. Automates the full development cycle: spec → plan → implement → review → clean.",
|
|
5
5
|
"author": { "name": "jhlee0409", "email": "relee6203@gmail.com" },
|
|
6
6
|
"homepage": "https://github.com/jhlee0409/all-for-claudecode",
|
package/MIGRATION.md
CHANGED
|
@@ -1,5 +1,29 @@
|
|
|
1
1
|
# Migration Guide
|
|
2
2
|
|
|
3
|
+
## v2.3.0 — Memory Management + analyze/validate Split
|
|
4
|
+
|
|
5
|
+
### What Changed
|
|
6
|
+
|
|
7
|
+
| Item | Before (v2.2.x) | After (v2.3.0) |
|
|
8
|
+
|------|-----------------|----------------|
|
|
9
|
+
| `/afc:analyze` | Artifact consistency check (= validate) | General-purpose code analysis (user-invocable, sonnet, context: fork) |
|
|
10
|
+
| `/afc:validate` | Did not exist separately | Artifact consistency check (model-only, haiku) |
|
|
11
|
+
| Agent MEMORY.md | Unbounded size | 100-line limit with auto-pruning |
|
|
12
|
+
| Memory directories | Unbounded file accumulation | Loading limits (most recent N files) + rotation in Clean phase |
|
|
13
|
+
| `/afc:doctor` Category 6 | Hook Health | Memory Health (new); Hook Health → 7, Version Sync → 8 |
|
|
14
|
+
| Checkpoint writes | Single location | Dual-write (project memory + auto-memory) |
|
|
15
|
+
|
|
16
|
+
### Migration Steps
|
|
17
|
+
|
|
18
|
+
**No action required for most users.** Changes are backwards-compatible and auto-applied.
|
|
19
|
+
|
|
20
|
+
- If you previously used `/afc:analyze` for artifact consistency checking, use `/afc:validate` instead (or let the pipeline invoke it automatically).
|
|
21
|
+
- Agent memory files (`.claude/agent-memory/afc-architect/MEMORY.md`, `.claude/agent-memory/afc-security/MEMORY.md`) exceeding 100 lines will be auto-pruned on next pipeline run.
|
|
22
|
+
- Memory subdirectories exceeding rotation thresholds will be auto-pruned during the Clean phase.
|
|
23
|
+
- Run `/afc:init` to update the `AFC:VERSION` tag in your CLAUDE.md.
|
|
24
|
+
|
|
25
|
+
---
|
|
26
|
+
|
|
3
27
|
## v2.0 — Rebrand: selfish-pipeline → all-for-claudecode
|
|
4
28
|
|
|
5
29
|
> all-for-claudecode v2.0 renames the package, plugin prefix, scripts, agents, and state files from `selfish` to `afc`.
|
package/README.md
CHANGED
|
@@ -119,7 +119,8 @@ Performance: ✓ no N+1 queries
|
|
|
119
119
|
| `/afc:tasks` | Task decomposition (auto-generated by implement) |
|
|
120
120
|
| `/afc:ideate` | Explore and structure a product idea |
|
|
121
121
|
| `/afc:launch` | Generate release artifacts (changelog, tag, publish) |
|
|
122
|
-
| `/afc:
|
|
122
|
+
| `/afc:validate` | Verify artifact consistency |
|
|
123
|
+
| `/afc:analyze` | General-purpose code and component analysis |
|
|
123
124
|
| `/afc:clarify` | Resolve spec ambiguities |
|
|
124
125
|
|
|
125
126
|
### Individual Command Examples
|
|
@@ -152,7 +153,7 @@ Every hook fires automatically — no configuration needed after install.
|
|
|
152
153
|
| `PreToolUse` | Blocks dangerous commands (`push --force`, `reset --hard`) |
|
|
153
154
|
| `PostToolUse` | Tracks file changes + auto-formats code |
|
|
154
155
|
| `SubagentStart` | Injects pipeline context into subagents |
|
|
155
|
-
| `Stop` | CI gate (shell) + code completeness check (
|
|
156
|
+
| `Stop` | CI gate (shell) + code completeness check (shell) |
|
|
156
157
|
| `SessionEnd` | Warns about unfinished pipeline |
|
|
157
158
|
| `PostToolUseFailure` | Diagnostic hints for known error patterns |
|
|
158
159
|
| `Notification` | Desktop alerts (macOS/Linux) |
|
|
@@ -165,7 +166,7 @@ Every hook fires automatically — no configuration needed after install.
|
|
|
165
166
|
| `WorktreeCreate` | Sets up worktree isolation for parallel workers |
|
|
166
167
|
| `WorktreeRemove` | Cleans up worktree after worker completion |
|
|
167
168
|
|
|
168
|
-
Handler types: `command` (shell scripts, all events), `prompt` (LLM single-turn, TaskCompleted)
|
|
169
|
+
Handler types: `command` (shell scripts, all events), `prompt` (LLM single-turn, TaskCompleted).
|
|
169
170
|
|
|
170
171
|
## Persistent Memory Agents
|
|
171
172
|
|
package/agents/afc-architect.md
CHANGED
|
@@ -52,6 +52,11 @@ At the end of each analysis:
|
|
|
52
52
|
1. Record new ADR decisions, discovered patterns, or architectural insights to MEMORY.md
|
|
53
53
|
2. Keep entries concise — only stable patterns and confirmed decisions
|
|
54
54
|
3. Remove outdated entries when architecture evolves
|
|
55
|
+
4. **Size limit**: MEMORY.md must not exceed **100 lines**. If adding new entries would exceed the limit:
|
|
56
|
+
- Remove the oldest ADR entries (keep the most recent decisions)
|
|
57
|
+
- Merge similar architecture patterns into single entries
|
|
58
|
+
- Remove entries for deleted/refactored code that no longer exists
|
|
59
|
+
- Prioritize: active constraints > recent patterns > historical ADRs
|
|
55
60
|
|
|
56
61
|
## Memory Format
|
|
57
62
|
|
package/agents/afc-security.md
CHANGED
|
@@ -45,6 +45,12 @@ At the end of each scan:
|
|
|
45
45
|
1. Record newly discovered vulnerability patterns to MEMORY.md
|
|
46
46
|
2. Record confirmed false positives with reasoning
|
|
47
47
|
3. Note project-specific security characteristics (e.g., input sanitization patterns, auth flows)
|
|
48
|
+
4. **Size limit**: MEMORY.md must not exceed **100 lines**. If adding new entries would exceed the limit:
|
|
49
|
+
- Remove the oldest false positive entries (patterns likely already fixed)
|
|
50
|
+
- Merge similar vulnerability patterns into single entries
|
|
51
|
+
- Remove entries for files/paths that no longer exist in the codebase
|
|
52
|
+
- Prioritize: active vulnerability patterns > project security profile > historical false positives
|
|
53
|
+
- Never remove entries for Critical-severity patterns regardless of age
|
|
48
54
|
|
|
49
55
|
## Memory Format
|
|
50
56
|
|
package/commands/analyze.md
CHANGED
|
@@ -1,125 +1,103 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: afc:analyze
|
|
3
|
-
description: "
|
|
4
|
-
argument-hint: "
|
|
5
|
-
user-invocable:
|
|
3
|
+
description: "General-purpose code and component analysis"
|
|
4
|
+
argument-hint: "<analysis target or question>"
|
|
5
|
+
user-invocable: true
|
|
6
6
|
context: fork
|
|
7
7
|
allowed-tools:
|
|
8
8
|
- Read
|
|
9
9
|
- Grep
|
|
10
10
|
- Glob
|
|
11
|
-
|
|
11
|
+
- WebSearch
|
|
12
|
+
model: sonnet
|
|
12
13
|
---
|
|
13
14
|
|
|
14
|
-
# /afc:analyze —
|
|
15
|
+
# /afc:analyze — Code Analysis
|
|
15
16
|
|
|
16
|
-
>
|
|
17
|
+
> Performs general-purpose codebase exploration and analysis based on a natural-language prompt.
|
|
17
18
|
> **Read-only** — does not modify any files.
|
|
18
19
|
|
|
19
20
|
## Arguments
|
|
20
21
|
|
|
21
|
-
- `$ARGUMENTS` — (
|
|
22
|
+
- `$ARGUMENTS` — (required) description of what to analyze (e.g., "trace the login flow", "root cause of rendering bug", "how does the hook system work")
|
|
22
23
|
|
|
23
24
|
## Config Load
|
|
24
25
|
|
|
25
26
|
**Always** read `.claude/afc.config.md` first. This file contains free-form markdown sections:
|
|
26
|
-
- `## Architecture` — architecture pattern, layers, import rules (primary reference for
|
|
27
|
+
- `## Architecture` — architecture pattern, layers, import rules (primary reference for structural analysis)
|
|
27
28
|
- `## Code Style` — language, naming conventions, lint rules
|
|
28
29
|
- `## Project Context` — framework, state management, testing, etc.
|
|
29
30
|
|
|
30
|
-
If config file is missing: read `CLAUDE.md` for architecture info.
|
|
31
|
+
If config file is missing: read `CLAUDE.md` for architecture info. Proceed without config if neither exists.
|
|
31
32
|
|
|
32
33
|
## Execution Steps
|
|
33
34
|
|
|
34
|
-
### 1.
|
|
35
|
+
### 1. Parse Analysis Intent
|
|
35
36
|
|
|
36
|
-
|
|
37
|
-
- **spec.md** (required)
|
|
38
|
-
- **plan.md** (required)
|
|
39
|
-
- **tasks.md** (if present)
|
|
40
|
-
- **research.md** (if present)
|
|
37
|
+
Classify `$ARGUMENTS` into one of these analysis modes:
|
|
41
38
|
|
|
42
|
-
|
|
39
|
+
| Mode | Trigger Keywords | Focus |
|
|
40
|
+
|------|-----------------|-------|
|
|
41
|
+
| **Root Cause** | "why", "cause", "bug", "error", "broken" | Error trace → data flow → hypothesis |
|
|
42
|
+
| **Structural** | "how", "architecture", "flow", "trace", "structure" | Component relationships, call graphs, data flow |
|
|
43
|
+
| **Exploratory** | "what", "find", "where", "which", "list" | File/function discovery, pattern matching |
|
|
44
|
+
| **Comparative** | "difference", "compare", "vs", "between" | Side-by-side analysis of implementations |
|
|
43
45
|
|
|
44
|
-
|
|
46
|
+
If the intent doesn't clearly match a mode, default to **Exploratory**.
|
|
45
47
|
|
|
46
|
-
|
|
48
|
+
### 2. Codebase Exploration
|
|
47
49
|
|
|
48
|
-
|
|
49
|
-
- Similar requirements within spec.md
|
|
50
|
-
- Overlapping tasks within tasks.md
|
|
50
|
+
Based on the classified mode:
|
|
51
51
|
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
52
|
+
1. **Identify scope**: determine which files/directories are relevant to `$ARGUMENTS`
|
|
53
|
+
2. **Read code**: read relevant files using Read tool (prioritize by relevance)
|
|
54
|
+
3. **Trace connections**: follow imports, function calls, and data flow
|
|
55
|
+
4. **Gather evidence**: collect specific code references (file:line) for findings
|
|
56
56
|
|
|
57
|
-
|
|
58
|
-
- spec → plan: Are all FR-*/NFR-* reflected in the plan?
|
|
59
|
-
- plan → tasks: Are all items in the plan's File Change Map present in tasks?
|
|
60
|
-
- spec → tasks: Are all requirements mapped to tasks?
|
|
57
|
+
Exploration should be guided by `{config.architecture}` layer structure when available.
|
|
61
58
|
|
|
62
|
-
|
|
63
|
-
- Terminology drift (different names for the same concept)
|
|
64
|
-
- Conflicting requirements
|
|
65
|
-
- Mismatches between technical decisions in plan and execution in tasks
|
|
59
|
+
### 3. Analysis
|
|
66
60
|
|
|
67
|
-
|
|
68
|
-
- Validate against MUST principles in .claude/afc/memory/principles.md if present
|
|
69
|
-
- Potential violations of {config.architecture} rules
|
|
61
|
+
Apply the appropriate analysis lens:
|
|
70
62
|
|
|
71
|
-
|
|
72
|
-
-
|
|
73
|
-
-
|
|
74
|
-
-
|
|
75
|
-
|
|
76
|
-
### 3. Severity Classification
|
|
77
|
-
|
|
78
|
-
| Severity | Criteria |
|
|
79
|
-
|----------|----------|
|
|
80
|
-
| **CRITICAL** | Principles violation, core feature blocker, security issue |
|
|
81
|
-
| **HIGH** | Duplication/conflict, untestable, coverage gap |
|
|
82
|
-
| **MEDIUM** | Terminology drift, ambiguous requirements |
|
|
83
|
-
| **LOW** | Style improvements, minor duplication |
|
|
63
|
+
- **Root Cause**: build a causal chain from symptom → intermediate causes → root cause
|
|
64
|
+
- **Structural**: map component relationships, identify coupling and cohesion patterns
|
|
65
|
+
- **Exploratory**: enumerate findings with code references
|
|
66
|
+
- **Comparative**: highlight similarities, differences, and tradeoffs
|
|
84
67
|
|
|
85
68
|
### 4. Output Results (console)
|
|
86
69
|
|
|
87
70
|
```markdown
|
|
88
|
-
##
|
|
71
|
+
## Analysis: {summary of $ARGUMENTS}
|
|
72
|
+
|
|
73
|
+
### Mode: {Root Cause | Structural | Exploratory | Comparative}
|
|
89
74
|
|
|
90
75
|
### Findings
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
###
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
| spec → tasks | {N}% |
|
|
102
|
-
|
|
103
|
-
### Metrics
|
|
104
|
-
- Total requirements: {N}
|
|
105
|
-
- Total tasks: {N}
|
|
106
|
-
- Issues: CRITICAL {N} / HIGH {N} / MEDIUM {N} / LOW {N}
|
|
107
|
-
|
|
108
|
-
### Next Steps
|
|
109
|
-
{Concrete action proposals for CRITICAL/HIGH issues}
|
|
76
|
+
{Numbered findings with code references (file:line)}
|
|
77
|
+
|
|
78
|
+
### Key Relationships
|
|
79
|
+
{Relevant component/function relationships discovered}
|
|
80
|
+
|
|
81
|
+
### Summary
|
|
82
|
+
{2-3 sentence conclusion answering the original question}
|
|
83
|
+
|
|
84
|
+
### Suggested Next Steps
|
|
85
|
+
{1-3 actionable suggestions based on the analysis}
|
|
110
86
|
```
|
|
111
87
|
|
|
112
88
|
### 5. Final Output
|
|
113
89
|
|
|
114
90
|
```
|
|
115
|
-
Analysis complete
|
|
116
|
-
├─
|
|
117
|
-
├─
|
|
118
|
-
|
|
91
|
+
Analysis complete: {short summary}
|
|
92
|
+
├─ Mode: {mode}
|
|
93
|
+
├─ Files explored: {N}
|
|
94
|
+
├─ Findings: {N}
|
|
95
|
+
└─ Suggested next steps: {N}
|
|
119
96
|
```
|
|
120
97
|
|
|
121
98
|
## Notes
|
|
122
99
|
|
|
123
100
|
- **Read-only**: Do not modify any files. Report only.
|
|
124
|
-
- **
|
|
125
|
-
- **
|
|
101
|
+
- **Scope discipline**: Focus analysis on what was asked. Do not expand scope unnecessarily.
|
|
102
|
+
- **Code references**: Always include `file:line` references so the user can navigate to relevant code.
|
|
103
|
+
- **Not artifact validation**: For spec/plan/tasks consistency checks, use `/afc:validate` instead.
|
package/commands/auto.md
CHANGED
|
@@ -170,7 +170,7 @@ Execute `/afc:spec` logic inline:
|
|
|
170
170
|
4. `[NEEDS CLARIFICATION]` items: **research first, then auto-resolve remaining** (clarify skipped if Phase 0.5 already ran)
|
|
171
171
|
- Items answerable via research → resolve with researched facts, tag `[RESEARCHED]`
|
|
172
172
|
- Items requiring user judgment → auto-resolve with best-guess, tag `[AUTO-RESOLVED]`
|
|
173
|
-
5. **Retrospective check**: if `.claude/afc/memory/retrospectives/` exists, load and check:
|
|
173
|
+
5. **Retrospective check**: if `.claude/afc/memory/retrospectives/` exists, load the **most recent 10 files** (sorted by filename descending) and check:
|
|
174
174
|
- Were there previous `[AUTO-RESOLVED]` items that turned out wrong? Flag similar patterns.
|
|
175
175
|
- Were there scope-related issues in past specs? Warn about similar ambiguities.
|
|
176
176
|
6. **Critic Loop until convergence** (safety cap: 5, follow Critic Loop rules):
|
|
@@ -191,9 +191,9 @@ Execute `/afc:plan` logic inline:
|
|
|
191
191
|
1. Load spec.md
|
|
192
192
|
2. If technical uncertainties exist → auto-resolve via WebSearch/code exploration → create research.md
|
|
193
193
|
3. **Memory loading** (skip gracefully if directories are empty or absent):
|
|
194
|
-
- **Quality history**: if `.claude/afc/memory/quality-history/*.json` exists, load recent
|
|
195
|
-
- **Decisions**: if `.claude/afc/memory/decisions/` exists, load
|
|
196
|
-
- **Reviews**: if `.claude/afc/memory/reviews/` exists, scan for recurring finding patterns (same file/category appearing in 2+ reviews). Flag as known risk areas.
|
|
194
|
+
- **Quality history**: if `.claude/afc/memory/quality-history/*.json` exists, load the **most recent 10 files** (sorted by filename descending) and display trend summary: "Last {N} pipelines: avg critic_fixes {X}, avg ci_failures {Y}, avg escalations {Z}". Use trends to inform plan risk assessment.
|
|
195
|
+
- **Decisions**: if `.claude/afc/memory/decisions/` exists, load the **most recent 30 files** (sorted by filename descending) and check for conflicts with the current feature's design direction. Flag any contradictions.
|
|
196
|
+
- **Reviews**: if `.claude/afc/memory/reviews/` exists, load the **most recent 15 files** (sorted by filename descending) and scan for recurring finding patterns (same file/category appearing in 2+ reviews). Flag as known risk areas.
|
|
197
197
|
4. Create `.claude/afc/specs/{feature}/plan.md`
|
|
198
198
|
- **If setting numerical targets (line counts etc.), include structure-analysis-based estimates** (e.g., "function A ~50 lines, component B ~80 lines → total ~130 lines")
|
|
199
199
|
5. **Critic Loop until convergence** (safety cap: 5, follow Critic Loop rules):
|
|
@@ -259,7 +259,7 @@ Execute `/afc:implement` logic inline — **follow all orchestration rules defin
|
|
|
259
259
|
#### Step 3.1: Task Generation + Validation
|
|
260
260
|
|
|
261
261
|
1. Generate tasks.md from plan.md File Change Map (as defined in implement.md Step 1.3)
|
|
262
|
-
2. **Retrospective check**: if `.claude/afc/memory/retrospectives/` exists, load and check:
|
|
262
|
+
2. **Retrospective check**: if `.claude/afc/memory/retrospectives/` exists, load the **most recent 10 files** (sorted by filename descending) and check:
|
|
263
263
|
- Were there previous parallel conflict issues ([P] file overlaps)? Flag similar file patterns.
|
|
264
264
|
- Were there tasks that were over-decomposed or under-decomposed? Adjust granularity.
|
|
265
265
|
3. Script validation (DAG + parallel overlap) — no critic loop, script-based only
|
|
@@ -414,8 +414,8 @@ Execute `/afc:review` logic inline — **follow all review perspectives defined
|
|
|
414
414
|
- **G. Maintainability** — AI/human comprehension, naming clarity, self-contained files (direct review)
|
|
415
415
|
- **H. Extensibility** — extension points, OCP, future modification cost (direct review)
|
|
416
416
|
4. **Auto-resolved validation**: Check all `[AUTO-RESOLVED]` items from spec phase — does the implementation match the guess? Flag mismatches as Critical.
|
|
417
|
-
5. **Past reviews check**: if `.claude/afc/memory/reviews/` exists, scan for recurring finding patterns across past review reports. Prioritize those areas.
|
|
418
|
-
6. **Retrospective check**: if `.claude/afc/memory/retrospectives/` exists, load and check:
|
|
417
|
+
5. **Past reviews check**: if `.claude/afc/memory/reviews/` exists, load the **most recent 15 files** (sorted by filename descending) and scan for recurring finding patterns across past review reports. Prioritize those areas.
|
|
418
|
+
6. **Retrospective check**: if `.claude/afc/memory/retrospectives/` exists, load the **most recent 10 files** (sorted by filename descending) and check:
|
|
419
419
|
- Were there recurring Critical finding categories in past reviews? Prioritize those perspectives.
|
|
420
420
|
- Were there false positives that wasted effort? Reduce sensitivity for those patterns.
|
|
421
421
|
7. **Critic Loop until convergence** (safety cap: 5, follow Critic Loop rules):
|
|
@@ -452,7 +452,23 @@ Artifact cleanup and codebase hygiene check after implementation and review:
|
|
|
452
452
|
- **If retrospective.md exists** → record as patterns missed by the Plan phase Critic Loop in `.claude/afc/memory/retrospectives/` (reuse as RISK checklist items in future runs)
|
|
453
453
|
- **If review-report.md exists** → copy to `.claude/afc/memory/reviews/{feature}-{date}.md` before .claude/afc/specs/ deletion
|
|
454
454
|
- **If research.md exists** and was not already persisted in Plan phase → copy to `.claude/afc/memory/research/{feature}.md`
|
|
455
|
-
- **Agent memory consolidation**: architect and security agents have already updated their persistent MEMORY.md during Review phase —
|
|
455
|
+
- **Agent memory consolidation**: architect and security agents have already updated their persistent MEMORY.md during Review phase. **Size enforcement**: check each agent's MEMORY.md line count — if either exceeds 100 lines, invoke the respective agent to self-prune:
|
|
456
|
+
```
|
|
457
|
+
Task("Memory cleanup: afc-architect", subagent_type: "afc:afc-architect",
|
|
458
|
+
prompt: "Your MEMORY.md exceeds 100 lines. Read it, prune old/redundant entries, and rewrite to under 100 lines following your size limit rules.")
|
|
459
|
+
```
|
|
460
|
+
(Same pattern for afc-security if needed. Skip if both are under 100 lines.)
|
|
461
|
+
- **Memory rotation**: for each memory subdirectory, check file count and prune oldest files if over threshold:
|
|
462
|
+
| Directory | Threshold | Action |
|
|
463
|
+
|-----------|-----------|--------|
|
|
464
|
+
| `quality-history/` | 30 files | Delete oldest files beyond threshold |
|
|
465
|
+
| `reviews/` | 40 files | Delete oldest files beyond threshold |
|
|
466
|
+
| `retrospectives/` | 30 files | Delete oldest files beyond threshold |
|
|
467
|
+
| `research/` | 50 files | Delete oldest files beyond threshold |
|
|
468
|
+
| `decisions/` | 60 files | Delete oldest files beyond threshold |
|
|
469
|
+
- Sort by filename ascending (oldest first), delete excess
|
|
470
|
+
- Log: `"Memory rotation: {dir} pruned {N} files"`
|
|
471
|
+
- Skip directories that do not exist or are under threshold
|
|
456
472
|
5. **Quality report** (structured pipeline metrics):
|
|
457
473
|
- Generate `.claude/afc/memory/quality-history/{feature}-{date}.json` with the following structure:
|
|
458
474
|
```json
|
|
@@ -482,7 +498,7 @@ Artifact cleanup and codebase hygiene check after implementation and review:
|
|
|
482
498
|
```
|
|
483
499
|
- Create `.claude/afc/memory/quality-history/` directory if it does not exist
|
|
484
500
|
6. **Checkpoint reset**:
|
|
485
|
-
- Clear `.claude/afc/memory/checkpoint.md` (pipeline complete = session goal achieved)
|
|
501
|
+
- Clear `.claude/afc/memory/checkpoint.md` **and** `~/.claude/projects/{ENCODED_PATH}/auto-memory/checkpoint.md` (pipeline complete = session goal achieved, dual-delete prevents stale checkpoint in either location; `ENCODED_PATH` = project path with `/` replaced by `-`)
|
|
486
502
|
7. **Timeline finalize**:
|
|
487
503
|
```bash
|
|
488
504
|
"${CLAUDE_PLUGIN_ROOT}/scripts/afc-pipeline-manage.sh" log pipeline-end "Pipeline complete: {feature}"
|
package/commands/doctor.md
CHANGED
|
@@ -84,7 +84,21 @@ Run ALL checks regardless of earlier failures. Do not short-circuit.
|
|
|
84
84
|
| No lingering safety tags | `git tag -l 'afc/pre-*'` | No tags, or tags match active pipeline | ⚠ Warning: lingering safety tag `afc/pre-{x}` found. Fix: `git tag -d afc/pre-{x}` |
|
|
85
85
|
| Checkpoint state | Read `.claude/afc/memory/checkpoint.md` if exists | No checkpoint (clean), or checkpoint is from current session | ⚠ Warning: stale checkpoint from {date}. Fix: run `/afc:resume` to continue or delete `.claude/afc/memory/checkpoint.md` |
|
|
86
86
|
|
|
87
|
-
### Category 6:
|
|
87
|
+
### Category 6: Memory Health
|
|
88
|
+
|
|
89
|
+
> Checks `.claude/afc/memory/` subdirectory sizes and agent memory file sizes. If memory directory does not exist, print `✓ No memory directory` and skip this category.
|
|
90
|
+
|
|
91
|
+
| Check | How | Pass | Fail |
|
|
92
|
+
|-------|-----|------|------|
|
|
93
|
+
| quality-history count | Count files in `.claude/afc/memory/quality-history/` | ≤ 30 files | ⚠ Warning: {N} files in quality-history/ (threshold: 30). Oldest files should be pruned. Fix: run a pipeline with `/afc:auto` (Clean phase auto-prunes) or manually delete oldest files |
|
|
94
|
+
| reviews count | Count files in `.claude/afc/memory/reviews/` | ≤ 40 files | ⚠ Warning: {N} files in reviews/ (threshold: 40). Fix: run a pipeline or manually delete oldest files |
|
|
95
|
+
| retrospectives count | Count files in `.claude/afc/memory/retrospectives/` | ≤ 30 files | ⚠ Warning: {N} files in retrospectives/ (threshold: 30). Fix: run a pipeline or manually delete oldest files |
|
|
96
|
+
| research count | Count files in `.claude/afc/memory/research/` | ≤ 50 files | ⚠ Warning: {N} files in research/ (threshold: 50). Fix: run a pipeline or manually delete oldest files |
|
|
97
|
+
| decisions count | Count files in `.claude/afc/memory/decisions/` | ≤ 60 files | ⚠ Warning: {N} files in decisions/ (threshold: 60). Fix: run a pipeline or manually delete oldest files |
|
|
98
|
+
| afc-architect MEMORY.md size | Count lines in `.claude/agent-memory/afc-architect/MEMORY.md` (if exists) | ≤ 100 lines | ⚠ Warning: afc-architect MEMORY.md is {N} lines (limit: 100). Fix: invoke `/afc:architect` to trigger self-pruning, or manually edit the file |
|
|
99
|
+
| afc-security MEMORY.md size | Count lines in `.claude/agent-memory/afc-security/MEMORY.md` (if exists) | ≤ 100 lines | ⚠ Warning: afc-security MEMORY.md is {N} lines (limit: 100). Fix: invoke `/afc:security` to trigger self-pruning, or manually edit the file |
|
|
100
|
+
|
|
101
|
+
### Category 7: Hook Health
|
|
88
102
|
|
|
89
103
|
| Check | How | Pass | Fail |
|
|
90
104
|
|-------|-----|------|------|
|
|
@@ -92,7 +106,7 @@ Run ALL checks regardless of earlier failures. Do not short-circuit.
|
|
|
92
106
|
| All scripts exist | For each script referenced in hooks.json, check file exists | All scripts found | ✗ Fix: reinstall plugin |
|
|
93
107
|
| Scripts executable | Check execute permission on each script in plugin's scripts/ | All have +x | Fix: `chmod +x` on the missing scripts, or reinstall plugin |
|
|
94
108
|
|
|
95
|
-
### Category
|
|
109
|
+
### Category 8: Version Sync (development only)
|
|
96
110
|
|
|
97
111
|
> Only run if current directory is the all-for-claudecode source repo (check for `package.json` with `"name": "all-for-claudecode"`).
|
|
98
112
|
|
package/commands/implement.md
CHANGED
|
@@ -96,7 +96,7 @@ If tasks.md already exists (e.g., from standalone `/afc:tasks` run): use as-is,
|
|
|
96
96
|
|
|
97
97
|
### 1.7. Retrospective Check
|
|
98
98
|
|
|
99
|
-
If `.claude/afc/memory/retrospectives/` exists, load and check:
|
|
99
|
+
If `.claude/afc/memory/retrospectives/` exists, load the **most recent 10 files** (sorted by filename descending) and check:
|
|
100
100
|
- Were there implementation issues in past pipelines (e.g., file conflicts, unexpected dependencies, CI failures after parallel execution)?
|
|
101
101
|
- Flag similar patterns in the current task list. Warn before implementation begins.
|
|
102
102
|
- Skip gracefully if directory is empty or absent.
|
package/commands/init.md
CHANGED
|
@@ -149,7 +149,7 @@ In the **unguarded** (non-marker-block) content only, find directives containing
|
|
|
149
149
|
- `code-reviewer`, `quality-reviewer`, `style-reviewer`, `api-reviewer`, `security-reviewer`, `performance-reviewer` — conflicts with afc:review
|
|
150
150
|
- `debugger` (in agent routing context) — conflicts with afc:debug
|
|
151
151
|
- `planner` (in agent routing context) — conflicts with afc:plan
|
|
152
|
-
- `analyst`, `verifier` — conflicts with afc:
|
|
152
|
+
- `analyst`, `verifier` — conflicts with afc:validate
|
|
153
153
|
- `test-engineer` — conflicts with afc:test
|
|
154
154
|
|
|
155
155
|
**C. Skill Routing Conflict Detection**
|
|
@@ -220,7 +220,8 @@ IMPORTANT: For requests matching the afc skill routing table below, always invok
|
|
|
220
220
|
| Debug | `afc:debug` | bug, error, broken, fix |
|
|
221
221
|
| Test | `afc:test` | test, coverage |
|
|
222
222
|
| Design | `afc:plan` | design, plan, how to implement |
|
|
223
|
-
|
|
|
223
|
+
| Validate | `afc:validate` | consistency, validate, validate artifacts |
|
|
224
|
+
| Analyze | `afc:analyze` | analyze, explore, investigate code, root cause |
|
|
224
225
|
| Spec | `afc:spec` | spec, specification |
|
|
225
226
|
| Tasks | `afc:tasks` | break down tasks, decompose |
|
|
226
227
|
| Research | `afc:research` | research, investigate |
|
package/commands/launch.md
CHANGED
|
@@ -21,7 +21,7 @@ model: sonnet
|
|
|
21
21
|
## Arguments
|
|
22
22
|
|
|
23
23
|
- `$ARGUMENTS` — (optional) One of:
|
|
24
|
-
- Version tag: `"v2.2.
|
|
24
|
+
- Version tag: e.g. `"v2.2.1"` — uses this as the release version
|
|
25
25
|
- `"auto"` — auto-detects version from package.json/Cargo.toml/pyproject.toml
|
|
26
26
|
- Not specified: prompts for version
|
|
27
27
|
|
package/commands/plan.md
CHANGED
|
@@ -45,9 +45,9 @@ If config file is missing:
|
|
|
45
45
|
4. Read **.claude/afc/memory/principles.md** (if present)
|
|
46
46
|
5. Read **CLAUDE.md** project context
|
|
47
47
|
6. **Memory loading** (skip gracefully if directories are empty or absent):
|
|
48
|
-
- **Quality history**: if `.claude/afc/memory/quality-history/*.json` exists, load recent
|
|
49
|
-
- **Decisions**: if `.claude/afc/memory/decisions/` exists, load
|
|
50
|
-
- **Reviews**: if `.claude/afc/memory/reviews/` exists, scan for recurring finding patterns (same file/category appearing in 2+ reviews). Flag as known risk areas.
|
|
48
|
+
- **Quality history**: if `.claude/afc/memory/quality-history/*.json` exists, load the **most recent 10 files** (sorted by filename descending) and display trend: "Last {N} pipelines: avg critic_fixes {X}, avg ci_failures {Y}". Use trends to inform risk assessment.
|
|
49
|
+
- **Decisions**: if `.claude/afc/memory/decisions/` exists, load the **most recent 30 files** (sorted by filename descending) and check for conflicts with the current feature's design direction.
|
|
50
|
+
- **Reviews**: if `.claude/afc/memory/reviews/` exists, load the **most recent 15 files** (sorted by filename descending) and scan for recurring finding patterns (same file/category appearing in 2+ reviews). Flag as known risk areas.
|
|
51
51
|
|
|
52
52
|
### 2. Clarification Check
|
|
53
53
|
|
|
@@ -205,7 +205,7 @@ Run the critic loop until convergence. Safety cap: 5 passes.
|
|
|
205
205
|
| **FEASIBILITY** | Is it compatible with the existing codebase? Are dependencies available? |
|
|
206
206
|
| **ARCHITECTURE** | Does it comply with {config.architecture} rules? |
|
|
207
207
|
| **CROSS_CONSISTENCY** | Spec↔Plan cross-artifact validation (see checklist below) |
|
|
208
|
-
| **RISK** | Are there any unidentified risks? Additionally, if `.claude/afc/memory/retrospectives/` directory contains files from previous pipeline runs, load
|
|
208
|
+
| **RISK** | Are there any unidentified risks? Additionally, if `.claude/afc/memory/retrospectives/` directory contains files from previous pipeline runs, load the **most recent 10 files** (sorted by filename descending) and check whether the current plan addresses the patterns recorded there. Tag matched patterns with `[RETRO-CHECKED]`. |
|
|
209
209
|
| **PRINCIPLES** | Does it not violate the MUST principles in principles.md? |
|
|
210
210
|
|
|
211
211
|
**CROSS_CONSISTENCY checklist** (mandatory, check all 5):
|
package/commands/resume.md
CHANGED
|
@@ -22,7 +22,9 @@ allowed-tools:
|
|
|
22
22
|
### 1. Load Checkpoint
|
|
23
23
|
|
|
24
24
|
Read `.claude/afc/memory/checkpoint.md`:
|
|
25
|
-
- If not found:
|
|
25
|
+
- If not found: check **auto-memory fallback** — read `~/.claude/projects/{ENCODED_PATH}/auto-memory/checkpoint.md` (where `ENCODED_PATH` = project path with `/` replaced by `-`):
|
|
26
|
+
- If fallback found: use it as the checkpoint source (auto-memory is written by `pre-compact-checkpoint.sh` during context compaction)
|
|
27
|
+
- If fallback also not found: output "No saved checkpoint found. Use `/afc:checkpoint` to create one, or checkpoints are created automatically on context compaction." then **stop**
|
|
26
28
|
- If found: parse the full contents (extract branch, commit hash, pipeline feature, task progress, modified files)
|
|
27
29
|
|
|
28
30
|
### 2. Validate Environment
|
package/commands/review.md
CHANGED
|
@@ -183,7 +183,7 @@ For each changed file, examine from the following perspectives:
|
|
|
183
183
|
|
|
184
184
|
### 5. Retrospective Check
|
|
185
185
|
|
|
186
|
-
If `.claude/afc/memory/retrospectives/` directory exists, load
|
|
186
|
+
If `.claude/afc/memory/retrospectives/` directory exists, load the **most recent 10 files** (sorted by filename descending) and check:
|
|
187
187
|
- Were there recurring Critical finding categories in past reviews? Prioritize those perspectives.
|
|
188
188
|
- Were there false positives that wasted effort? Reduce sensitivity for those patterns.
|
|
189
189
|
|
package/commands/spec.md
CHANGED
|
@@ -155,7 +155,7 @@ After writing the spec, check for `[NEEDS CLARIFICATION]` items:
|
|
|
155
155
|
|
|
156
156
|
### 4. Retrospective Check
|
|
157
157
|
|
|
158
|
-
If `.claude/afc/memory/retrospectives/` directory exists, load
|
|
158
|
+
If `.claude/afc/memory/retrospectives/` directory exists, load the **most recent 10 files** (sorted by filename descending) and check:
|
|
159
159
|
- Were there previous `[AUTO-RESOLVED]` items that turned out wrong? Flag similar patterns.
|
|
160
160
|
- Were there scope-related issues in past specs? Warn about similar ambiguities.
|
|
161
161
|
|
package/commands/tasks.md
CHANGED
|
@@ -87,7 +87,7 @@ Decompose tasks per Phase defined in plan.md.
|
|
|
87
87
|
|
|
88
88
|
### 3. Retrospective Check
|
|
89
89
|
|
|
90
|
-
If `.claude/afc/memory/retrospectives/` directory exists, load
|
|
90
|
+
If `.claude/afc/memory/retrospectives/` directory exists, load the **most recent 10 files** (sorted by filename descending) and check:
|
|
91
91
|
- Were there previous parallel conflict issues ([P] file overlaps)? Flag similar file patterns.
|
|
92
92
|
- Were there tasks that were over-decomposed or under-decomposed? Adjust granularity.
|
|
93
93
|
|
|
@@ -138,7 +138,7 @@ Tasks generated
|
|
|
138
138
|
├─ Phases: {phase count}
|
|
139
139
|
├─ Coverage: FR {coverage}%, NFR {coverage}%
|
|
140
140
|
├─ Critic: converged ({N} passes, {M} fixes, {E} escalations)
|
|
141
|
-
└─ Next step: /afc:
|
|
141
|
+
└─ Next step: /afc:validate (optional) or /afc:implement
|
|
142
142
|
```
|
|
143
143
|
|
|
144
144
|
## Notes
|
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: afc:validate
|
|
3
|
+
description: "Artifact consistency validation (read-only)"
|
|
4
|
+
argument-hint: "[validation scope: spec-plan, tasks-only]"
|
|
5
|
+
user-invocable: false
|
|
6
|
+
context: fork
|
|
7
|
+
allowed-tools:
|
|
8
|
+
- Read
|
|
9
|
+
- Grep
|
|
10
|
+
- Glob
|
|
11
|
+
model: haiku
|
|
12
|
+
---
|
|
13
|
+
|
|
14
|
+
# /afc:validate — Artifact Consistency Validation
|
|
15
|
+
|
|
16
|
+
> Validates consistency and quality across spec.md, plan.md, and tasks.md.
|
|
17
|
+
> **Read-only** — does not modify any files.
|
|
18
|
+
|
|
19
|
+
## Arguments
|
|
20
|
+
|
|
21
|
+
- `$ARGUMENTS` — (optional) limit validation scope (e.g., "spec-plan", "tasks-only")
|
|
22
|
+
|
|
23
|
+
## Config Load
|
|
24
|
+
|
|
25
|
+
**Always** read `.claude/afc.config.md` first. This file contains free-form markdown sections:
|
|
26
|
+
- `## Architecture` — architecture pattern, layers, import rules (primary reference for this command)
|
|
27
|
+
- `## Code Style` — language, naming conventions, lint rules
|
|
28
|
+
- `## Project Context` — framework, state management, testing, etc.
|
|
29
|
+
|
|
30
|
+
If config file is missing: read `CLAUDE.md` for architecture info. Assume "Layered Architecture" if neither source has it.
|
|
31
|
+
|
|
32
|
+
## Execution Steps
|
|
33
|
+
|
|
34
|
+
### 1. Load Artifacts
|
|
35
|
+
|
|
36
|
+
From `.claude/afc/specs/{feature}/`:
|
|
37
|
+
- **spec.md** (required)
|
|
38
|
+
- **plan.md** (required)
|
|
39
|
+
- **tasks.md** (if present)
|
|
40
|
+
- **research.md** (if present)
|
|
41
|
+
|
|
42
|
+
Warn about missing files but proceed with what is available.
|
|
43
|
+
|
|
44
|
+
### 2. Run Validation
|
|
45
|
+
|
|
46
|
+
Validate across 6 categories:
|
|
47
|
+
|
|
48
|
+
#### A. Duplication Detection (DUPLICATION)
|
|
49
|
+
- Similar requirements within spec.md
|
|
50
|
+
- Overlapping tasks within tasks.md
|
|
51
|
+
|
|
52
|
+
#### B. Ambiguity Detection (AMBIGUITY)
|
|
53
|
+
- Unmeasurable adjectives ("appropriate", "fast", "good")
|
|
54
|
+
- Residual TODO/TBD/FIXME markers
|
|
55
|
+
- Incomplete sentences
|
|
56
|
+
|
|
57
|
+
#### C. Coverage Gaps (COVERAGE)
|
|
58
|
+
- spec → plan: Are all FR-*/NFR-* reflected in the plan?
|
|
59
|
+
- plan → tasks: Are all items in the plan's File Change Map present in tasks?
|
|
60
|
+
- spec → tasks: Are all requirements mapped to tasks?
|
|
61
|
+
|
|
62
|
+
#### D. Inconsistencies (INCONSISTENCY)
|
|
63
|
+
- Terminology drift (different names for the same concept)
|
|
64
|
+
- Conflicting requirements
|
|
65
|
+
- Mismatches between technical decisions in plan and execution in tasks
|
|
66
|
+
|
|
67
|
+
#### E. Principles Compliance (PRINCIPLES)
|
|
68
|
+
- Validate against MUST principles in .claude/afc/memory/principles.md if present
|
|
69
|
+
- Potential violations of {config.architecture} rules
|
|
70
|
+
|
|
71
|
+
#### F. Unidentified Risks (RISK)
|
|
72
|
+
- Are there risks not identified in plan.md?
|
|
73
|
+
- External dependency risks
|
|
74
|
+
- Potential performance bottlenecks
|
|
75
|
+
|
|
76
|
+
### 3. Severity Classification
|
|
77
|
+
|
|
78
|
+
| Severity | Criteria |
|
|
79
|
+
|----------|----------|
|
|
80
|
+
| **CRITICAL** | Principles violation, core feature blocker, security issue |
|
|
81
|
+
| **HIGH** | Duplication/conflict, untestable, coverage gap |
|
|
82
|
+
| **MEDIUM** | Terminology drift, ambiguous requirements |
|
|
83
|
+
| **LOW** | Style improvements, minor duplication |
|
|
84
|
+
|
|
85
|
+
### 4. Output Results (console)
|
|
86
|
+
|
|
87
|
+
```markdown
|
|
88
|
+
## Consistency Analysis Results: {feature name}
|
|
89
|
+
|
|
90
|
+
### Findings
|
|
91
|
+
| ID | Category | Severity | Location | Summary | Recommended Action |
|
|
92
|
+
|----|----------|----------|----------|---------|-------------------|
|
|
93
|
+
| A-001 | COVERAGE | HIGH | spec FR-003 | No mapping in tasks | Add task |
|
|
94
|
+
| A-002 | AMBIGUITY | MEDIUM | spec NFR-001 | "quickly" is unmeasurable | Add numeric threshold |
|
|
95
|
+
|
|
96
|
+
### Coverage Summary
|
|
97
|
+
| Mapping | Coverage |
|
|
98
|
+
|---------|----------|
|
|
99
|
+
| spec → plan | {N}% |
|
|
100
|
+
| plan → tasks | {N}% |
|
|
101
|
+
| spec → tasks | {N}% |
|
|
102
|
+
|
|
103
|
+
### Metrics
|
|
104
|
+
- Total requirements: {N}
|
|
105
|
+
- Total tasks: {N}
|
|
106
|
+
- Issues: CRITICAL {N} / HIGH {N} / MEDIUM {N} / LOW {N}
|
|
107
|
+
|
|
108
|
+
### Next Steps
|
|
109
|
+
{Concrete action proposals for CRITICAL/HIGH issues}
|
|
110
|
+
```
|
|
111
|
+
|
|
112
|
+
### 5. Final Output
|
|
113
|
+
|
|
114
|
+
```
|
|
115
|
+
Analysis complete
|
|
116
|
+
├─ Found: CRITICAL {N} / HIGH {N} / MEDIUM {N} / LOW {N}
|
|
117
|
+
├─ Coverage: spec→plan {N}%, plan→tasks {N}%, spec→tasks {N}%
|
|
118
|
+
└─ Recommended: {next action}
|
|
119
|
+
```
|
|
120
|
+
|
|
121
|
+
## Notes
|
|
122
|
+
|
|
123
|
+
- **Read-only**: Do not modify any files. Report only.
|
|
124
|
+
- **Avoid false positives**: Do not over-flag ambiguity. Consider context.
|
|
125
|
+
- **Optional**: Not required in the pipeline. Can proceed plan → implement directly.
|
|
@@ -34,7 +34,7 @@ Quantitatively inspect changed files within the Phase against `{config.code_styl
|
|
|
34
34
|
After passing the Phase gate, automatically save session state:
|
|
35
35
|
|
|
36
36
|
1. Create `.claude/afc/memory/` directory if it does not exist
|
|
37
|
-
2. Write/update `.claude/afc/memory/checkpoint.md
|
|
37
|
+
2. Write/update `.claude/afc/memory/checkpoint.md` **and** `~/.claude/projects/{ENCODED_PATH}/auto-memory/checkpoint.md` (dual-write for compaction resilience — `ENCODED_PATH` = project path with `/` replaced by `-`):
|
|
38
38
|
|
|
39
39
|
```markdown
|
|
40
40
|
# Phase Gate Checkpoint
|
package/package.json
CHANGED
|
@@ -243,7 +243,7 @@ check_phase_ssot() {
|
|
|
243
243
|
# Sub-check B: Every command name should map to a valid phase or be a known non-phase command
|
|
244
244
|
# Non-phase commands that are not pipeline phases
|
|
245
245
|
# NOTE: Update this list when adding non-phase commands to commands/
|
|
246
|
-
local non_phase_cmds="auto|init|doctor|principles|checkpoint|resume|launch|ideate|research|architect|security|debug|analyze|test"
|
|
246
|
+
local non_phase_cmds="auto|init|doctor|principles|checkpoint|resume|launch|ideate|research|architect|security|debug|analyze|validate|test"
|
|
247
247
|
local commands_dir="$PROJECT_DIR/commands"
|
|
248
248
|
if [ -d "$commands_dir" ]; then
|
|
249
249
|
for cmd_file in "$commands_dir"/*.md; do
|
|
@@ -37,7 +37,13 @@ if afc_is_ci_exempt "${CURRENT_PHASE:-}"; then
|
|
|
37
37
|
exit 0
|
|
38
38
|
fi
|
|
39
39
|
|
|
40
|
-
# Implement
|
|
40
|
+
# Implement phase: allow individual task completions without CI
|
|
41
|
+
# CI runs AFTER all tasks finish. Stop gate enforces CI at pipeline stop.
|
|
42
|
+
if [ "${CURRENT_PHASE:-}" = "implement" ]; then
|
|
43
|
+
exit 0
|
|
44
|
+
fi
|
|
45
|
+
|
|
46
|
+
# Review/Clean phases require CI to pass
|
|
41
47
|
CI_TIME="$(afc_state_read ciPassedAt 2>/dev/null || echo '')"
|
|
42
48
|
CI_TIME="$(printf '%s' "$CI_TIME" | tr -dc '0-9')"
|
|
43
49
|
CI_TIME="${CI_TIME:-0}"
|