sedd 0.1.12 → 0.1.13

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.
@@ -316,7 +316,20 @@ Ao gerar tasks, VARRER clarify.md por TODOS os `[TASK_SOURCE:*]` tags:
316
316
  - Cada tag com tipo `edge-case` → task de validacao/protecao
317
317
  - Cada tag com tipo `constraint` → task de teste negativo
318
318
 
319
- Based on all decisions and TASK_SOURCE tags, create tasks:
319
+ Based on all decisions and TASK_SOURCE tags, **use the CLI to add tasks**:
320
+
321
+ ```bash
322
+ sedd tasks '[{"story":"Foundation","description":"Create ThemeContext in src/contexts/ThemeContext.tsx"},{"story":"Foundation","description":"Add theme column to users table prisma/schema.prisma"},{"story":"US1","description":"Create ThemeToggle component src/components/ThemeToggle.tsx"},{"story":"US1","description":"Add toggle to settings page src/pages/settings.tsx"},{"story":"US1","description":"Implement theme API endpoint src/api/user/theme.ts"}]'
323
+ ```
324
+
325
+ This automatically:
326
+ - Appends tasks to `tasks.md` with correct IDs (T001-001, T001-002...)
327
+ - Updates `_meta.json` (tasksTotal, status → in-progress)
328
+ - Creates GitHub issues for each task (if GitHub integration is configured)
329
+
330
+ **Do NOT manually write tasks.md** — the CLI handles file creation and GitHub sync.
331
+
332
+ The CLI generates `tasks.md` with this structure:
320
333
 
321
334
  ```markdown
322
335
  # Tasks - Migration 001
@@ -335,7 +348,11 @@ Total: 5 | Completed: 0 | Pending: 5
335
348
  - [ ] T001-003 [US1] Create ThemeToggle component `src/components/ThemeToggle.tsx`
336
349
  - [ ] T001-004 [US1] Add toggle to settings page `src/pages/settings.tsx`
337
350
  - [ ] T001-005 [US1] Implement theme API endpoint `src/api/user/theme.ts`
351
+ ```
338
352
 
353
+ After adding tasks via CLI, manually add the `## Dependencies` section to tasks.md:
354
+
355
+ ```markdown
339
356
  ## Dependencies
340
357
 
341
358
  T001-001, T001-002 → T001-003 → T001-004
@@ -114,28 +114,26 @@ For each task in order:
114
114
 
115
115
  3. **Execute the task**
116
116
 
117
- 4. **Update ALL task files** (CRITICAL - keep them in sync):
117
+ 4. **Mark task as completed using CLI** (CRITICAL - syncs with GitHub automatically):
118
118
 
119
- a. **Update tasks.md** in migration folder - change `[ ]` to `[x]`:
120
- ```markdown
121
- # Before
122
- - [ ] T001-001 [Foundation] Create ThemeContext
123
-
124
- # After
125
- - [x] T001-001 [Foundation] Create ThemeContext
119
+ ```bash
120
+ sedd complete T001-001
126
121
  ```
127
122
 
128
- b. **Update progress.md** - mark completed with timestamp:
123
+ This automatically:
124
+ - Updates `tasks.md` (`[ ]` → `[x]`)
125
+ - Increments `tasksCompleted` in `_meta.json`
126
+ - If GitHub integration is configured:
127
+ - Moves the issue to "Done" on the project board
128
+ - Comments on the issue with progress
129
+ - When all tasks complete: closes the source issue
130
+
131
+ After running `sedd complete`, also update **progress.md** manually:
129
132
  ```markdown
130
133
  - [x] T001-001 [10:30 → 10:45] Create ThemeContext
131
134
  ```
132
135
 
133
- c. **Update _meta.json** - increment tasksCompleted:
134
- ```json
135
- "tasksCompleted": 1
136
- ```
137
-
138
- 5. **Verify sync** - All three files must show same completed count
136
+ 5. **Verify sync** - tasks.md, _meta.json and progress.md must show same completed count
139
137
 
140
138
  ### Step 5.6: Validate Against Expectations (CRITICAL - Before Marking Done)
141
139
 
@@ -610,10 +608,8 @@ Stops after migration 002.
610
608
 
611
609
  ## Rules
612
610
 
613
- - **CRITICAL: Update ALL 3 files when completing a task:**
614
- 1. `{migration}/tasks.md` - change `[ ]` to `[x]`
615
- 2. `progress.md` - mark task with `[x]` and timestamps
616
- 3. `_meta.json` - increment tasksCompleted count
611
+ - **CRITICAL: Use `sedd complete <task-id>` to mark tasks done** (syncs tasks.md, _meta.json, and GitHub automatically)
612
+ - Then manually update `progress.md` with timestamps
617
613
  - ONE task in-progress at a time
618
614
  - **With `--all` flag:** NO prompts between migrations, commit only at end
619
615
  - **Without flag:** Ask about commit after each migration completes
@@ -623,11 +619,12 @@ Stops after migration 002.
623
619
 
624
620
  ## File Sync Checklist
625
621
 
626
- After completing each task, verify:
622
+ After running `sedd complete T001-001`, verify:
627
623
  ```
628
- ✓ tasks.md → - [x] T001-001 ...
629
- progress.md - [x] T001-001 [time] ...
630
- _meta.json "tasksCompleted": N
624
+ ✓ tasks.md → - [x] T001-001 ... (auto by sedd complete)
625
+ _meta.json "tasksCompleted": N (auto by sedd complete)
626
+ progress.md - [x] T001-001 [time] ... (manual update)
627
+ ✓ GitHub issue → moved to Done column (auto if configured)
631
628
  ```
632
629
 
633
630
  If files are out of sync, fix immediately before continuing.
@@ -75,9 +75,21 @@ T002-001 = Migration 002, Task 1
75
75
  | Integration | External services |
76
76
  | Tests | Unit, integration tests |
77
77
 
78
- ### Step 5: Write tasks.md
78
+ ### Step 5: Add tasks via CLI
79
79
 
80
- Append to `{currentMigration}/tasks.md`:
80
+ **CRITICAL:** Use the `sedd tasks` CLI command to add tasks. This automatically:
81
+ - Appends tasks to `tasks.md` with correct IDs
82
+ - Updates `_meta.json` (tasksTotal, status)
83
+ - Creates GitHub issues for each task (if GitHub integration is configured)
84
+ - Checks WIP limits on the board
85
+
86
+ ```bash
87
+ sedd tasks '[{"story":"Foundation","description":"Create database migration for new tables"},{"story":"Foundation","description":"Set up API route structure"},{"story":"US1","description":"Create ThemeContext with localStorage persistence"},{"story":"US1","description":"Build ThemeToggle component"},{"story":"US1","description":"Add toggle to settings page"},{"story":"US2","description":"Create user preference API endpoint"},{"story":"US2","description":"Implement cross-device sync"},{"story":"Tests","description":"Write unit tests for ThemeContext"}]'
88
+ ```
89
+
90
+ **Do NOT manually edit tasks.md or _meta.json** — the CLI handles both and syncs with GitHub.
91
+
92
+ The CLI generates `tasks.md` with this structure:
81
93
 
82
94
  ```markdown
83
95
  # Tasks - Migration 001
@@ -106,7 +118,11 @@ Total: 8 | Completed: 0 | Pending: 8
106
118
 
107
119
  ### Tests
108
120
  - [ ] T001-008 [Tests] Write unit tests for ThemeContext
121
+ ```
122
+
123
+ After adding tasks via CLI, manually add the `## Dependencies` section to tasks.md:
109
124
 
125
+ ```markdown
110
126
  ## Dependencies
111
127
 
112
128
  T001-001, T001-002 → T001-003 → T001-004 → T001-005
@@ -116,6 +132,8 @@ T001-003 → T001-008
116
132
 
117
133
  ### Step 6: Update _meta.json
118
134
 
135
+ The CLI also updates `_meta.json` automatically:
136
+
119
137
  ```json
120
138
  {
121
139
  "migrations": {
@@ -285,11 +285,17 @@ Próximo passo: Reverter alterações que violam restrições.
285
285
 
286
286
  ### Step 8: Create Follow-up Tasks (if gaps)
287
287
 
288
- If gaps found and `--auto` flag or user confirms:
288
+ If gaps found and `--auto` flag or user confirms, **use the CLI to add tasks**:
289
289
 
290
- ```markdown
291
- # New tasks added to tasks.md
290
+ ```bash
291
+ sedd tasks '[{"story":"Follow-up","description":"Implement session persistence for theme"},{"story":"Follow-up","description":"Add session storage fallback"}]'
292
+ ```
292
293
 
294
+ This automatically creates GitHub issues for the follow-up tasks and updates _meta.json.
295
+ **Do NOT manually append to tasks.md** — use the CLI.
296
+
297
+ The CLI will add to tasks.md:
298
+ ```markdown
293
299
  - [ ] T001-NEW-001 [Follow-up] Implement session persistence for theme
294
300
  - [ ] T001-NEW-002 [Follow-up] Add session storage fallback
295
301
  ```
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sedd",
3
- "version": "0.1.12",
3
+ "version": "0.1.13",
4
4
  "description": "SEDD - Spec & Expectation Driven Development. A phase-based specification workflow for AI-assisted development.",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",