@lumenflow/cli 2.5.0 → 2.6.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/README.md +11 -8
- package/dist/__tests__/gates-config.test.js +304 -0
- package/dist/__tests__/init-scripts.test.js +111 -0
- package/dist/__tests__/templates-sync.test.js +219 -0
- package/dist/gates.js +64 -15
- package/dist/init.js +90 -0
- package/dist/orchestrate-init-status.js +37 -9
- package/dist/orchestrate-initiative.js +10 -4
- package/dist/sync-templates.js +137 -5
- package/dist/wu-prep.js +131 -8
- package/dist/wu-spawn.js +7 -2
- package/package.json +7 -7
- package/templates/core/.lumenflow/constraints.md.template +61 -3
- package/templates/core/LUMENFLOW.md.template +85 -23
- package/templates/core/ai/onboarding/agent-invocation-guide.md.template +157 -0
- package/templates/core/ai/onboarding/agent-safety-card.md.template +227 -0
- package/templates/core/ai/onboarding/docs-generation.md.template +277 -0
- package/templates/core/ai/onboarding/first-wu-mistakes.md.template +49 -7
- package/templates/core/ai/onboarding/quick-ref-commands.md.template +343 -110
- package/templates/core/ai/onboarding/release-process.md.template +8 -2
- package/templates/core/ai/onboarding/starting-prompt.md.template +407 -0
- package/templates/core/ai/onboarding/test-ratchet.md.template +131 -0
- package/templates/core/ai/onboarding/troubleshooting-wu-done.md.template +91 -38
- package/templates/core/ai/onboarding/vendor-support.md.template +219 -0
- package/templates/vendors/claude/.claude/skills/context-management/SKILL.md.template +13 -1
- package/templates/vendors/claude/.claude/skills/execution-memory/SKILL.md.template +14 -16
- package/templates/vendors/claude/.claude/skills/orchestration/SKILL.md.template +48 -4
- package/templates/vendors/claude/.claude/skills/worktree-discipline/SKILL.md.template +5 -1
- package/templates/vendors/claude/.claude/skills/wu-lifecycle/SKILL.md.template +19 -8
|
@@ -2,185 +2,418 @@
|
|
|
2
2
|
|
|
3
3
|
**Last updated:** {{DATE}}
|
|
4
4
|
|
|
5
|
+
Complete reference for all CLI commands. Organized by category for quick discovery.
|
|
6
|
+
|
|
5
7
|
---
|
|
6
8
|
|
|
7
|
-
##
|
|
9
|
+
## Setup & Development
|
|
10
|
+
|
|
11
|
+
**For this monorepo (development):**
|
|
12
|
+
|
|
13
|
+
| Command | Description |
|
|
14
|
+
| ------------------------ | --------------------------------------- |
|
|
15
|
+
| `pnpm setup` | Install deps and build CLI (first time) |
|
|
16
|
+
| `pnpm build` | Build all packages |
|
|
17
|
+
| `pnpm build:dist` | Build distribution packages |
|
|
18
|
+
| `pnpm dev` | Start development mode |
|
|
19
|
+
| `pnpm clean` | Clean build artifacts and caches |
|
|
20
|
+
| `pnpm pack:all` | Pack all packages for distribution |
|
|
21
|
+
| `pnpm lumenflow:init` | Scaffold LumenFlow in a project |
|
|
22
|
+
| `pnpm docs:sync` | Sync agent docs (for upgrades) |
|
|
23
|
+
| `pnpm sync:templates` | Sync templates to project |
|
|
24
|
+
| `pnpm lumenflow:upgrade` | Upgrade LumenFlow packages |
|
|
25
|
+
| `pnpm lumenflow:doctor` | Diagnose LumenFlow configuration |
|
|
26
|
+
|
|
27
|
+
**For external projects (end users):**
|
|
28
|
+
|
|
29
|
+
```bash
|
|
30
|
+
# Install CLI
|
|
31
|
+
pnpm add -D @lumenflow/cli # or: npm install -D @lumenflow/cli
|
|
32
|
+
|
|
33
|
+
# Initialize LumenFlow
|
|
34
|
+
pnpm exec lumenflow
|
|
8
35
|
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
| `pnpm exec lumenflow init --force` | Overwrite existing files |
|
|
15
|
-
| `pnpm exec lumenflow docs:sync` | Sync agent docs to existing project (for upgrades) |
|
|
16
|
-
| `pnpm exec lumenflow docs:sync --force` | Overwrite existing agent docs |
|
|
17
|
-
| `pnpm exec lumenflow doctor` | Diagnose LumenFlow configuration issues |
|
|
36
|
+
# With client-specific overlays
|
|
37
|
+
pnpm exec lumenflow --client claude # Claude Code
|
|
38
|
+
pnpm exec lumenflow --client cursor # Cursor IDE
|
|
39
|
+
pnpm exec lumenflow --client all # All clients
|
|
40
|
+
```
|
|
18
41
|
|
|
19
42
|
---
|
|
20
43
|
|
|
21
|
-
## WU
|
|
44
|
+
## WU Lifecycle
|
|
45
|
+
|
|
46
|
+
| Command | Description |
|
|
47
|
+
| --------------------------------------------- | ---------------------------------------------- |
|
|
48
|
+
| `pnpm wu:create --id WU-XXX --lane <Lane> ..` | Create new WU spec (see required fields below) |
|
|
49
|
+
| `pnpm wu:claim --id WU-XXX --lane <Lane>` | Claim WU and create worktree |
|
|
50
|
+
| `pnpm wu:prep --id WU-XXX` | Run gates in worktree, prep for wu:done |
|
|
51
|
+
| `pnpm wu:done --id WU-XXX` | Complete WU (merge, stamp, cleanup) from main |
|
|
52
|
+
| `pnpm wu:edit --id WU-XXX --field value` | Edit WU spec fields |
|
|
53
|
+
| `pnpm wu:block --id WU-XXX --reason "..."` | Block WU with reason |
|
|
54
|
+
| `pnpm wu:unblock --id WU-XXX` | Unblock WU |
|
|
55
|
+
| `pnpm wu:release --id WU-XXX` | Release orphaned WU (in_progress to ready) |
|
|
56
|
+
| `pnpm wu:status --id WU-XXX` | Show WU status, location, valid commands |
|
|
57
|
+
| `pnpm wu:spawn --id WU-XXX --client <client>` | Generate sub-agent spawn prompt |
|
|
58
|
+
| `pnpm wu:spawn --id WU-XXX --no-context` | Spawn prompt without memory context injection |
|
|
59
|
+
|
|
60
|
+
### WU Maintenance
|
|
61
|
+
|
|
62
|
+
| Command | Description |
|
|
63
|
+
| -------------------------------- | ---------------------------------------- |
|
|
64
|
+
| `pnpm wu:validate --id WU-XXX` | Validate WU spec |
|
|
65
|
+
| `pnpm wu:preflight --id WU-XXX` | Pre-flight checks before wu:done |
|
|
66
|
+
| `pnpm wu:recover --id WU-XXX` | Analyze and fix WU state inconsistencies |
|
|
67
|
+
| `pnpm wu:repair --id WU-XXX` | Repair WU state issues |
|
|
68
|
+
| `pnpm wu:prune` | Clean stale worktrees |
|
|
69
|
+
| `pnpm wu:cleanup --id WU-XXX` | Cleanup after PR merge (PR-only) |
|
|
70
|
+
| `pnpm wu:deps --id WU-XXX` | Show WU dependencies |
|
|
71
|
+
| `pnpm wu:infer-lane --id WU-XXX` | Infer lane from code paths/description |
|
|
72
|
+
| `pnpm wu:delete --id WU-XXX` | Delete WU spec and cleanup |
|
|
73
|
+
| `pnpm wu:unlock-lane --lane <L>` | Unlock stuck lane |
|
|
22
74
|
|
|
23
|
-
|
|
24
|
-
| --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------- |
|
|
25
|
-
| `pnpm wu:create --id WU-XXX --lane <Lane> --title "Title" --description "..." --acceptance "..." --code-paths "path" --test-paths-unit "path" --exposure backend-only --spec-refs "lumenflow://plans/WU-XXX-plan.md"` | Create new WU (default: spec branch mode) |
|
|
26
|
-
| `pnpm wu:create ... --direct` | Create WU directly on main (legacy/emergency) |
|
|
27
|
-
| `pnpm wu:create ... --plan` | Also create plan template in $LUMENFLOW_HOME/plans/ |
|
|
28
|
-
| `pnpm wu:claim --id WU-XXX --lane <Lane>` | Claim WU (auto-merges spec branch if needed) |
|
|
29
|
-
| `pnpm wu:spawn --id WU-XXX --client <client>` | Spawn sub-agent prompt with client guidance |
|
|
30
|
-
| `pnpm wu:edit --id WU-1039 --exposure backend-only` | Edit WU spec (supports exposure updates on done WUs) |
|
|
31
|
-
| `pnpm wu:done --id WU-XXX` | Complete WU (merge, stamp, cleanup) - primary method |
|
|
32
|
-
| `pnpm wu:block --id WU-XXX --reason "Reason"` | Block a WU |
|
|
33
|
-
| `pnpm wu:unblock --id WU-XXX` | Unblock a WU |
|
|
34
|
-
| `pnpm wu:cleanup --id WU-XXX` | PR-only: cleanup after PR merge (see note below) |
|
|
35
|
-
| `pnpm wu:cleanup --artifacts` | Remove build artifacts in current worktree |
|
|
36
|
-
| `pnpm wu:delete --id WU-XXX` | Delete WU spec and cleanup |
|
|
37
|
-
| `pnpm wu:unlock-lane --lane <Lane>` | Unlock stuck lane |
|
|
75
|
+
---
|
|
38
76
|
|
|
39
|
-
|
|
77
|
+
## Gates & Quality
|
|
78
|
+
|
|
79
|
+
| Command | Description |
|
|
80
|
+
| --------------------------------- | -------------------------------- |
|
|
81
|
+
| `pnpm gates` | Run all quality gates |
|
|
82
|
+
| `pnpm gates --docs-only` | Run gates for docs changes |
|
|
83
|
+
| `pnpm format` | Format all files (Prettier) |
|
|
84
|
+
| `pnpm format:check` | Check formatting without changes |
|
|
85
|
+
| `pnpm lint` | Run ESLint |
|
|
86
|
+
| `pnpm typecheck` | Run TypeScript type checking |
|
|
87
|
+
| `pnpm test` | Run all tests (Vitest) |
|
|
88
|
+
| `pnpm spec:linter` | Validate WU specs (all) |
|
|
89
|
+
| `pnpm lane:health` | Check lane config health |
|
|
90
|
+
| `pnpm lane:suggest --paths "..."` | Suggest lane for code paths |
|
|
40
91
|
|
|
41
|
-
|
|
92
|
+
---
|
|
42
93
|
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
|
46
|
-
|
|
|
94
|
+
## Memory & Sessions
|
|
95
|
+
|
|
96
|
+
| Command | Description |
|
|
97
|
+
| ----------------------------------- | ---------------------------------- |
|
|
98
|
+
| `pnpm mem:init --wu WU-XXX` | Initialize memory for WU |
|
|
99
|
+
| `pnpm mem:start --wu WU-XXX` | Start a memory session |
|
|
100
|
+
| `pnpm mem:checkpoint --wu WU-XXX` | Save progress checkpoint |
|
|
101
|
+
| `pnpm mem:ready --wu WU-XXX` | Check pending nodes |
|
|
102
|
+
| `pnpm mem:export --wu WU-XXX` | Export memory as markdown |
|
|
103
|
+
| `pnpm mem:create "msg" --wu WU-XXX` | Create memory node (bug discovery) |
|
|
104
|
+
| `pnpm mem:signal "msg" --wu WU-XXX` | Broadcast coordination signal |
|
|
105
|
+
| `pnpm mem:inbox --wu WU-XXX` | Check coordination signals |
|
|
106
|
+
| `pnpm mem:summarize --wu WU-XXX` | Summarize memory context |
|
|
107
|
+
| `pnpm mem:triage --wu WU-XXX` | Triage discovered bugs |
|
|
108
|
+
| `pnpm mem:context --wu WU-XXX` | Get context for current lane/WU |
|
|
109
|
+
| `pnpm mem:context ... --lane <L>` | Filter context by lane (WU-1292) |
|
|
110
|
+
| `pnpm mem:delete --id <node-id>` | Delete/archive a memory node |
|
|
111
|
+
| `pnpm mem:cleanup` | Clean up stale memory data |
|
|
47
112
|
|
|
48
|
-
|
|
113
|
+
---
|
|
49
114
|
|
|
50
|
-
|
|
115
|
+
## State Management
|
|
51
116
|
|
|
52
|
-
|
|
53
|
-
|
|
117
|
+
| Command | Description |
|
|
118
|
+
| ---------------------- | --------------------------- |
|
|
119
|
+
| `pnpm state:doctor` | Diagnose state store issues |
|
|
120
|
+
| `pnpm state:cleanup` | Clean up stale state data |
|
|
121
|
+
| `pnpm signal:cleanup` | Clean up stale signals |
|
|
122
|
+
| `pnpm state:bootstrap` | Bootstrap state store |
|
|
123
|
+
| `pnpm backlog:prune` | Clean stale backlog entries |
|
|
54
124
|
|
|
55
|
-
|
|
125
|
+
---
|
|
56
126
|
|
|
57
|
-
|
|
127
|
+
## Dependencies
|
|
58
128
|
|
|
59
|
-
|
|
129
|
+
| Command | Description |
|
|
130
|
+
| ------------------------------- | ------------------------------ |
|
|
131
|
+
| `pnpm deps:add --pkg <name>` | Add dependency to package |
|
|
132
|
+
| `pnpm deps:remove --pkg <name>` | Remove dependency from package |
|
|
60
133
|
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
134
|
+
---
|
|
135
|
+
|
|
136
|
+
## Plans
|
|
137
|
+
|
|
138
|
+
Plans are markdown documents that capture goals, scope, approach, and success criteria before implementation begins. They link to WUs (via `spec_refs`) and initiatives (via `related_plan`).
|
|
65
139
|
|
|
66
|
-
|
|
140
|
+
### Plan Storage
|
|
67
141
|
|
|
68
|
-
|
|
69
|
-
- **In-progress WUs**: Edits write directly to the active worktree's WU YAML file
|
|
142
|
+
Plans are stored in the repo at `docs/04-operations/plans/` by default (configurable via `directories.plansDir` in `.lumenflow.config.yaml`).
|
|
70
143
|
|
|
71
|
-
|
|
144
|
+
| Command | Description |
|
|
145
|
+
| ----------------------------------------------------- | ------------------------------------------- |
|
|
146
|
+
| `pnpm initiative:plan --initiative INIT-XXX` | Link existing plan to initiative |
|
|
147
|
+
| `pnpm initiative:plan --initiative INIT-XXX --create` | Create plan template and link to initiative |
|
|
72
148
|
|
|
73
|
-
|
|
149
|
+
### Linking Plans
|
|
150
|
+
|
|
151
|
+
**To an initiative:**
|
|
152
|
+
|
|
153
|
+
```bash
|
|
154
|
+
# Create a new plan template
|
|
155
|
+
pnpm initiative:plan --initiative INIT-001 --create
|
|
156
|
+
|
|
157
|
+
# Link an existing plan file
|
|
158
|
+
pnpm initiative:plan --initiative INIT-001 --plan docs/04-operations/plans/my-plan.md
|
|
159
|
+
```
|
|
160
|
+
|
|
161
|
+
**To a WU (via spec_refs):**
|
|
162
|
+
|
|
163
|
+
```bash
|
|
164
|
+
# When creating a WU
|
|
165
|
+
pnpm wu:create --id WU-123 --lane "Framework: Core" --title "Feature" \
|
|
166
|
+
--spec-refs "lumenflow://plans/WU-123-plan.md"
|
|
167
|
+
|
|
168
|
+
# Or edit an existing WU
|
|
169
|
+
pnpm wu:edit --id WU-123 --spec-refs "lumenflow://plans/WU-123-plan.md"
|
|
170
|
+
```
|
|
171
|
+
|
|
172
|
+
### Plan URI Format
|
|
173
|
+
|
|
174
|
+
Plans use the `lumenflow://plans/` URI scheme for references:
|
|
175
|
+
|
|
176
|
+
- `lumenflow://plans/INIT-001-auth-system.md` - Initiative plan
|
|
177
|
+
- `lumenflow://plans/WU-123-plan.md` - WU-specific plan
|
|
74
178
|
|
|
75
179
|
---
|
|
76
180
|
|
|
77
|
-
##
|
|
181
|
+
## Initiatives
|
|
78
182
|
|
|
79
|
-
| Command
|
|
80
|
-
|
|
|
81
|
-
| `pnpm
|
|
82
|
-
| `pnpm
|
|
83
|
-
| `pnpm
|
|
84
|
-
| `pnpm
|
|
85
|
-
| `pnpm
|
|
86
|
-
| `pnpm
|
|
87
|
-
| `pnpm
|
|
88
|
-
| `pnpm lane:suggest` | Suggest lane for code paths|
|
|
183
|
+
| Command | Description |
|
|
184
|
+
| ------------------------------------------------------------- | ----------------------------- |
|
|
185
|
+
| `pnpm initiative:create --id INIT-XXX ...` | Create new initiative |
|
|
186
|
+
| `pnpm initiative:edit --id INIT-XXX ...` | Edit initiative fields |
|
|
187
|
+
| `pnpm initiative:list` | List all initiatives |
|
|
188
|
+
| `pnpm initiative:status --id INIT-XXX` | Show initiative status |
|
|
189
|
+
| `pnpm initiative:add-wu --initiative INIT-XXX --wu WU-XXX` | Add WU to initiative |
|
|
190
|
+
| `pnpm initiative:remove-wu --initiative INIT-XXX --wu WU-XXX` | Remove WU from initiative |
|
|
191
|
+
| `pnpm initiative:bulk-assign --id INIT-XXX` | Bulk assign WUs to initiative |
|
|
89
192
|
|
|
90
193
|
---
|
|
91
194
|
|
|
92
|
-
##
|
|
195
|
+
## Orchestration
|
|
93
196
|
|
|
94
|
-
| Command
|
|
95
|
-
|
|
|
96
|
-
| `pnpm
|
|
97
|
-
| `pnpm
|
|
98
|
-
| `pnpm
|
|
99
|
-
| `pnpm
|
|
197
|
+
| Command | Description |
|
|
198
|
+
| -------------------------------------------- | -------------------------------- |
|
|
199
|
+
| `pnpm orchestrate:initiative --id INIT-XXX` | Orchestrate initiative execution |
|
|
200
|
+
| `pnpm orchestrate:init-status --id INIT-XXX` | Compact initiative progress view |
|
|
201
|
+
| `pnpm orchestrate:monitor` | Monitor spawn/agent activity |
|
|
202
|
+
| `pnpm spawn:list` | List active spawned agents |
|
|
100
203
|
|
|
101
204
|
---
|
|
102
205
|
|
|
103
|
-
##
|
|
206
|
+
## Metrics & Flow
|
|
104
207
|
|
|
105
|
-
| Command
|
|
106
|
-
|
|
|
107
|
-
| `
|
|
108
|
-
| `
|
|
109
|
-
| `
|
|
110
|
-
| `git push origin lane/<lane>/wu-xxx` | Push to remote |
|
|
111
|
-
| `git fetch origin` | Fetch remote changes |
|
|
112
|
-
| `git rebase origin/main` | Update from main |
|
|
208
|
+
| Command | Description |
|
|
209
|
+
| ----------------------- | ---------------------------- |
|
|
210
|
+
| `pnpm flow:report` | Generate flow metrics report |
|
|
211
|
+
| `pnpm flow:bottlenecks` | Identify flow bottlenecks |
|
|
212
|
+
| `pnpm metrics:snapshot` | Capture metrics snapshot |
|
|
113
213
|
|
|
114
214
|
---
|
|
115
215
|
|
|
116
|
-
##
|
|
216
|
+
## Documentation
|
|
117
217
|
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
218
|
+
| Command | Description |
|
|
219
|
+
| -------------------- | -------------------------- |
|
|
220
|
+
| `pnpm docs:generate` | Generate CLI documentation |
|
|
221
|
+
| `pnpm docs:validate` | Validate CLI documentation |
|
|
121
222
|
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
223
|
+
---
|
|
224
|
+
|
|
225
|
+
## Release
|
|
226
|
+
|
|
227
|
+
| Command | Description |
|
|
228
|
+
| ------------------------ | ------------------------------- |
|
|
229
|
+
| `pnpm release` | Run release workflow |
|
|
230
|
+
| `pnpm pre-release:check` | Pre-release validation checks |
|
|
231
|
+
| `pnpm changeset` | Create changeset for versioning |
|
|
232
|
+
| `pnpm version` | Apply changeset versions |
|
|
233
|
+
| `pnpm release:changeset` | Build and publish via changeset |
|
|
234
|
+
|
|
235
|
+
---
|
|
236
|
+
|
|
237
|
+
## Agent Utilities
|
|
238
|
+
|
|
239
|
+
| Command | Description |
|
|
240
|
+
| ------------------------- | ---------------------------------- |
|
|
241
|
+
| `pnpm agent:issues-query` | Query GitHub issues for agent work |
|
|
125
242
|
|
|
126
243
|
---
|
|
127
244
|
|
|
128
|
-
## Workflow Sequence
|
|
245
|
+
## Workflow Sequence (Quick Reference)
|
|
129
246
|
|
|
130
247
|
```bash
|
|
131
|
-
# 1. Create
|
|
132
|
-
pnpm wu:create --id WU-
|
|
133
|
-
--description "Context:
|
|
248
|
+
# 1. Create WU
|
|
249
|
+
pnpm wu:create --id WU-XXX --lane "Framework: Core" --title "Add feature" \
|
|
250
|
+
--description "Context: ... Problem: ... Solution: ..." \
|
|
134
251
|
--acceptance "Criterion 1" --acceptance "Criterion 2" \
|
|
135
|
-
--code-paths "
|
|
136
|
-
--test-paths-unit "
|
|
252
|
+
--code-paths "src/file.ts" \
|
|
253
|
+
--test-paths-unit "src/__tests__/file.test.ts" \
|
|
137
254
|
--exposure backend-only \
|
|
138
|
-
--spec-refs "lumenflow
|
|
255
|
+
--spec-refs "~/.lumenflow/plans/WU-XXX-plan.md"
|
|
139
256
|
|
|
140
|
-
# 2. Claim (
|
|
141
|
-
pnpm wu:claim --id WU-
|
|
142
|
-
cd worktrees/framework-core-wu-
|
|
257
|
+
# 2. Claim (creates worktree)
|
|
258
|
+
pnpm wu:claim --id WU-XXX --lane "Framework: Core"
|
|
259
|
+
cd worktrees/framework-core-wu-xxx
|
|
143
260
|
|
|
144
|
-
# 3.
|
|
261
|
+
# 3. Implement (TDD)
|
|
145
262
|
# ... write tests first, then code ...
|
|
146
263
|
|
|
147
264
|
# 4. Commit
|
|
148
|
-
git add .
|
|
149
|
-
git commit -m "feat: add feature"
|
|
150
|
-
git push origin lane/framework-core/wu-001
|
|
265
|
+
git add . && git commit -m "feat: description"
|
|
151
266
|
|
|
152
|
-
# 5.
|
|
153
|
-
pnpm
|
|
267
|
+
# 5. Prep (runs gates in worktree)
|
|
268
|
+
pnpm wu:prep --id WU-XXX
|
|
154
269
|
|
|
155
|
-
# 6. Complete
|
|
156
|
-
cd /path/to/main
|
|
157
|
-
pnpm wu:done --id WU-001
|
|
270
|
+
# 6. Complete (from main - copy from wu:prep output)
|
|
271
|
+
cd /path/to/main && pnpm wu:done --id WU-XXX
|
|
158
272
|
```
|
|
159
273
|
|
|
160
274
|
---
|
|
161
275
|
|
|
162
|
-
##
|
|
276
|
+
## wu:create Required Fields (Code WUs)
|
|
277
|
+
|
|
278
|
+
For code changes, you must include **all** of the following (or wu:create will fail):
|
|
279
|
+
|
|
280
|
+
- `--description`
|
|
281
|
+
- `--acceptance` (repeatable, at least one)
|
|
282
|
+
- `--code-paths` (repeatable)
|
|
283
|
+
- `--test-paths-unit` or `--test-paths-e2e` (automated tests required)
|
|
284
|
+
- `--exposure` (ui | api | backend-only | documentation)
|
|
285
|
+
- `--spec-refs` (required for type: feature)
|
|
286
|
+
|
|
287
|
+
Documentation WUs can omit code/test paths but should set `--type documentation` and `--exposure documentation`.
|
|
288
|
+
|
|
289
|
+
---
|
|
290
|
+
|
|
291
|
+
## Strict WU Validation (WU-1329)
|
|
292
|
+
|
|
293
|
+
**WU validation is strict by default.** Commands validate that code paths and test paths actually exist on disk.
|
|
294
|
+
|
|
295
|
+
### Affected Commands
|
|
163
296
|
|
|
297
|
+
| Command | Strict Behavior |
|
|
298
|
+
| ------------------- | --------------------------------------------------- |
|
|
299
|
+
| `wu:create` | Validates `--code-paths` and `--test-paths-*` exist |
|
|
300
|
+
| `wu:edit` | Validates edited paths exist |
|
|
301
|
+
| `wu:validate` | Treats warnings as errors by default |
|
|
302
|
+
| `initiative:add-wu` | Validates WU schema and completeness before linking |
|
|
303
|
+
|
|
304
|
+
### Strict Mode (Default)
|
|
305
|
+
|
|
306
|
+
When strict validation runs:
|
|
307
|
+
|
|
308
|
+
- Non-existent `code_paths` cause **failure**
|
|
309
|
+
- Non-existent `test_paths` cause **failure**
|
|
310
|
+
- Validation warnings are treated as **errors**
|
|
311
|
+
|
|
312
|
+
This prevents WU specs from referencing files that do not exist, improving spec quality and reducing broken WUs.
|
|
313
|
+
|
|
314
|
+
### Bypassing Strict Validation
|
|
315
|
+
|
|
316
|
+
Use `--no-strict` to bypass path existence checks (not recommended):
|
|
317
|
+
|
|
318
|
+
```bash
|
|
319
|
+
# Create WU with paths that don't exist yet (planning ahead)
|
|
320
|
+
pnpm wu:create --lane "Framework: Core" --title "New feature" \
|
|
321
|
+
--code-paths "src/new-file.ts" \
|
|
322
|
+
--no-strict
|
|
323
|
+
|
|
324
|
+
# Validate with warnings as advisory only
|
|
325
|
+
pnpm wu:validate --id WU-XXX --no-strict
|
|
164
326
|
```
|
|
165
|
-
type(scope): description
|
|
166
327
|
|
|
167
|
-
|
|
328
|
+
**When to use `--no-strict`:**
|
|
329
|
+
|
|
330
|
+
- Planning WUs before implementation (paths don't exist yet)
|
|
331
|
+
- Migrating specs from external systems
|
|
332
|
+
- Emergency situations (logged for audit)
|
|
333
|
+
|
|
334
|
+
**Usage is logged** for accountability.
|
|
335
|
+
|
|
336
|
+
### Agent Expectations
|
|
337
|
+
|
|
338
|
+
Agents should:
|
|
339
|
+
|
|
340
|
+
1. **Prefer strict mode** (default) for all WU operations
|
|
341
|
+
2. **Avoid `--no-strict`** unless explicitly necessary
|
|
342
|
+
3. **Fix path issues** rather than bypassing validation
|
|
343
|
+
4. **Create files first** before referencing them in WU specs
|
|
344
|
+
|
|
345
|
+
---
|
|
346
|
+
|
|
347
|
+
## Lane Inference Requirement (Sub-Lanes)
|
|
348
|
+
|
|
349
|
+
If you use a sub-lane like `Experience: UI`, you **must** have a lane taxonomy:
|
|
350
|
+
|
|
351
|
+
- Ensure `.lumenflow.lane-inference.yaml` exists, or
|
|
352
|
+
- Generate it with `pnpm lane:suggest --output .lumenflow.lane-inference.yaml`
|
|
353
|
+
|
|
354
|
+
Without this file, sub-lane validation will fail.
|
|
355
|
+
|
|
356
|
+
---
|
|
357
|
+
|
|
358
|
+
## Local / Offline Behavior (No Remote)
|
|
359
|
+
|
|
360
|
+
By default, `wu:create` and `wu:claim` expect an `origin` remote and will fetch `origin/main`.
|
|
361
|
+
|
|
362
|
+
For local-only or offline development, add this to `.lumenflow.config.yaml`:
|
|
363
|
+
|
|
364
|
+
```yaml
|
|
365
|
+
git:
|
|
366
|
+
requireRemote: false
|
|
168
367
|
```
|
|
169
368
|
|
|
170
|
-
|
|
369
|
+
When `requireRemote: false`:
|
|
370
|
+
|
|
371
|
+
- `wu:create` skips remote fetch operations
|
|
372
|
+
- `wu:claim` works without pushing to origin
|
|
373
|
+
- Useful for air-gapped environments, testing/evaluation, or pre-remote development
|
|
374
|
+
|
|
375
|
+
When `requireRemote: true` (default):
|
|
171
376
|
|
|
172
|
-
-
|
|
173
|
-
-
|
|
174
|
-
- `docs: update README`
|
|
175
|
-
- `test: add unit tests for calculator`
|
|
377
|
+
- Operations fail with a clear error if no `origin` remote exists
|
|
378
|
+
- Ensures team visibility via remote branches
|
|
176
379
|
|
|
177
380
|
---
|
|
178
381
|
|
|
179
|
-
## File Paths
|
|
382
|
+
## Key File Paths
|
|
180
383
|
|
|
181
384
|
| Path | Description |
|
|
182
385
|
| ----------------------------------------- | -------------------- |
|
|
183
386
|
| `docs/04-operations/tasks/wu/WU-XXX.yaml` | WU specification |
|
|
184
387
|
| `docs/04-operations/tasks/status.md` | Current status board |
|
|
388
|
+
| `docs/04-operations/tasks/backlog.md` | Backlog summary |
|
|
185
389
|
| `.lumenflow/stamps/WU-XXX.done` | Completion stamp |
|
|
186
390
|
| `worktrees/<lane>-wu-xxx/` | Worktree directory |
|
|
391
|
+
|
|
392
|
+
---
|
|
393
|
+
|
|
394
|
+
## Common Patterns
|
|
395
|
+
|
|
396
|
+
### wu:prep + wu:done (Two-Step Completion)
|
|
397
|
+
|
|
398
|
+
```bash
|
|
399
|
+
# From worktree: run gates, get instruction
|
|
400
|
+
pnpm wu:prep --id WU-XXX
|
|
401
|
+
# Output: cd /path/to/main && pnpm wu:done --id WU-XXX
|
|
402
|
+
|
|
403
|
+
# From main: merge, stamp, cleanup
|
|
404
|
+
cd /path/to/main && pnpm wu:done --id WU-XXX
|
|
405
|
+
```
|
|
406
|
+
|
|
407
|
+
### Memory Checkpoint (Progress Safety)
|
|
408
|
+
|
|
409
|
+
```bash
|
|
410
|
+
pnpm mem:checkpoint --wu WU-XXX # Before risky operations
|
|
411
|
+
pnpm mem:inbox --since 30m # Check for signals (NOT TaskOutput)
|
|
412
|
+
```
|
|
413
|
+
|
|
414
|
+
### Bug Discovery (Mid-WU)
|
|
415
|
+
|
|
416
|
+
```bash
|
|
417
|
+
# Capture bug, don't fix out-of-scope
|
|
418
|
+
pnpm mem:create 'Bug: description' --type discovery --tags bug --wu WU-XXX
|
|
419
|
+
```
|
|
@@ -171,6 +171,8 @@ npm view @lumenflow/cli versions --json | tail -5
|
|
|
171
171
|
|
|
172
172
|
The public docs at <https://lumenflow.dev> are built from `apps/docs/`.
|
|
173
173
|
|
|
174
|
+
**Automatic Generation:** CLI and config reference docs are automatically generated from code. See [Automatic Docs Generation](./docs-generation.md) for details on the single-source-of-truth pattern.
|
|
175
|
+
|
|
174
176
|
### Deployment
|
|
175
177
|
|
|
176
178
|
Starlight docs are deployed **manually** via Vercel CLI:
|
|
@@ -238,6 +240,7 @@ The `apps/github-app/package.json` must have `"private": true` to prevent npm pu
|
|
|
238
240
|
|
|
239
241
|
- [ ] All acceptance criteria met
|
|
240
242
|
- [ ] Gates pass (`pnpm gates`)
|
|
243
|
+
- [ ] Pre-release checks pass (`pnpm pre-release:check`)
|
|
241
244
|
- [ ] CHANGELOG updated (if maintained)
|
|
242
245
|
|
|
243
246
|
### Release Steps (Automated)
|
|
@@ -261,6 +264,7 @@ If you need more control:
|
|
|
261
264
|
1. **Complete WU** (includes version bump commit)
|
|
262
265
|
|
|
263
266
|
```bash
|
|
267
|
+
pnpm pre-release:check
|
|
264
268
|
pnpm wu:done --id WU-XXXX
|
|
265
269
|
```
|
|
266
270
|
|
|
@@ -303,12 +307,14 @@ If you need more control:
|
|
|
303
307
|
|
|
304
308
|
| Change Type | npm | Docs | GitHub App |
|
|
305
309
|
| ---------------- | ------------- | ------ | ------------ |
|
|
306
|
-
| Bug fix in CLI | Tag + publish |
|
|
307
|
-
| New CLI command | Tag + publish |
|
|
310
|
+
| Bug fix in CLI | Tag + publish | Auto\* | No |
|
|
311
|
+
| New CLI command | Tag + publish | Auto\* | No |
|
|
308
312
|
| Docs-only update | No | Deploy | No |
|
|
309
313
|
| GitHub App fix | No | No | Auto on push |
|
|
310
314
|
| Full release | Tag + publish | Deploy | Auto |
|
|
311
315
|
|
|
316
|
+
\* CLI/config reference docs regenerate automatically during `wu:done` when trigger files change. See [Automatic Docs Generation](./docs-generation.md).
|
|
317
|
+
|
|
312
318
|
---
|
|
313
319
|
|
|
314
320
|
## Troubleshooting Deployments
|