get-shit-done-cc 1.3.12 → 1.3.14
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.
|
@@ -243,6 +243,43 @@ Use for: Technology selection, architecture decisions, design choices, feature p
|
|
|
243
243
|
See `./checkpoints.md` for comprehensive checkpoint guidance.
|
|
244
244
|
</task_types>
|
|
245
245
|
|
|
246
|
+
<tdd_annotation>
|
|
247
|
+
Tasks can include `tdd="true"` attribute when TDD improves quality:
|
|
248
|
+
|
|
249
|
+
**Structure:**
|
|
250
|
+
```xml
|
|
251
|
+
<task type="auto" tdd="true">
|
|
252
|
+
<name>Task N: [Name]</name>
|
|
253
|
+
<files>[paths]</files>
|
|
254
|
+
<test-first>[What test to write first - the failing assertion]</test-first>
|
|
255
|
+
<action>[Implementation to make test pass]</action>
|
|
256
|
+
<verify>[Tests pass, behavior works]</verify>
|
|
257
|
+
<done>[Criteria]</done>
|
|
258
|
+
</task>
|
|
259
|
+
```
|
|
260
|
+
|
|
261
|
+
**When to add tdd="true":**
|
|
262
|
+
- Business logic with defined inputs/outputs
|
|
263
|
+
- API endpoints with request/response contracts
|
|
264
|
+
- Data transformations and parsing
|
|
265
|
+
- Validation rules
|
|
266
|
+
- Algorithms with testable behavior
|
|
267
|
+
|
|
268
|
+
**When NOT to add tdd="true":**
|
|
269
|
+
- UI layout and styling
|
|
270
|
+
- Configuration changes
|
|
271
|
+
- Glue code connecting existing components
|
|
272
|
+
- One-off scripts
|
|
273
|
+
|
|
274
|
+
**Execution flow (when tdd="true"):**
|
|
275
|
+
1. Claude writes failing test from `<test-first>`
|
|
276
|
+
2. Claude implements from `<action>` until test passes
|
|
277
|
+
3. Claude refactors if needed (tests still pass)
|
|
278
|
+
4. Claude commits atomic change
|
|
279
|
+
|
|
280
|
+
See `./tdd.md` for comprehensive TDD guidance.
|
|
281
|
+
</tdd_annotation>
|
|
282
|
+
|
|
246
283
|
<context_references>
|
|
247
284
|
Use @file references to load context for the prompt:
|
|
248
285
|
|
|
@@ -347,6 +384,26 @@ Claude: "How? What type? What library? Where?"
|
|
|
347
384
|
Claude can implement this immediately.
|
|
348
385
|
</just_right>
|
|
349
386
|
|
|
387
|
+
<tdd_example>
|
|
388
|
+
TDD task example:
|
|
389
|
+
|
|
390
|
+
```xml
|
|
391
|
+
<task type="auto" tdd="true">
|
|
392
|
+
<name>Task 2: Create email validation utility</name>
|
|
393
|
+
<files>src/lib/validation.ts, src/lib/validation.test.ts</files>
|
|
394
|
+
<test-first>
|
|
395
|
+
Test: isValidEmail returns true for valid emails, false for invalid
|
|
396
|
+
Cases: "user@example.com" → true, "invalid" → false, "" → false, "user@" → false
|
|
397
|
+
</test-first>
|
|
398
|
+
<action>Implement isValidEmail using regex pattern. Handle edge cases: empty string, missing @, missing domain.</action>
|
|
399
|
+
<verify>npm test -- validation.test.ts passes all cases</verify>
|
|
400
|
+
<done>Email validation works for all edge cases, tests document behavior</done>
|
|
401
|
+
</task>
|
|
402
|
+
```
|
|
403
|
+
|
|
404
|
+
Claude executes this with RED → GREEN → REFACTOR cycle, producing atomic commits.
|
|
405
|
+
</tdd_example>
|
|
406
|
+
|
|
350
407
|
<too_detailed>
|
|
351
408
|
Writing the actual code in the plan. Trust Claude to implement from clear instructions.
|
|
352
409
|
</too_detailed>
|
|
@@ -0,0 +1,168 @@
|
|
|
1
|
+
<overview>
|
|
2
|
+
TDD is about design quality, not coverage metrics. The red-green-refactor cycle forces you to think about behavior before implementation, producing cleaner interfaces and more testable code.
|
|
3
|
+
|
|
4
|
+
**Principle:** If you can describe the behavior as `expect(fn(input)).toBe(output)` before writing `fn`, TDD improves the result.
|
|
5
|
+
</overview>
|
|
6
|
+
|
|
7
|
+
<detection>
|
|
8
|
+
## When TDD Improves Quality
|
|
9
|
+
|
|
10
|
+
**TDD candidates (add `tdd="true"`, include `<test-first>`):**
|
|
11
|
+
- Business logic with defined inputs/outputs
|
|
12
|
+
- API endpoints with request/response contracts
|
|
13
|
+
- Data transformations, parsing, formatting
|
|
14
|
+
- Validation rules and constraints
|
|
15
|
+
- Algorithms with testable behavior
|
|
16
|
+
- State machines and workflows
|
|
17
|
+
- Utility functions with clear specifications
|
|
18
|
+
|
|
19
|
+
**Skip TDD (standard `type="auto"`):**
|
|
20
|
+
- UI layout, styling, visual components
|
|
21
|
+
- Configuration changes
|
|
22
|
+
- Glue code connecting existing components
|
|
23
|
+
- One-off scripts and migrations
|
|
24
|
+
- Simple CRUD with no business logic
|
|
25
|
+
- Exploratory prototyping
|
|
26
|
+
|
|
27
|
+
**Heuristic:** Can you write `expect(fn(input)).toBe(output)` before writing `fn`?
|
|
28
|
+
→ Yes: TDD will help
|
|
29
|
+
→ No: Implement first, add tests after if needed
|
|
30
|
+
</detection>
|
|
31
|
+
|
|
32
|
+
<execution_flow>
|
|
33
|
+
## Red-Green-Refactor Cycle
|
|
34
|
+
|
|
35
|
+
**RED - Write failing test:**
|
|
36
|
+
1. Create test file following project conventions
|
|
37
|
+
2. Write test describing expected behavior (from `<test-first>` element)
|
|
38
|
+
3. Run test - it MUST fail
|
|
39
|
+
4. If test passes: feature exists or test is wrong. Investigate.
|
|
40
|
+
5. Commit: `test: add failing test for [feature]`
|
|
41
|
+
|
|
42
|
+
**GREEN - Implement to pass:**
|
|
43
|
+
1. Write minimal code to make test pass
|
|
44
|
+
2. No cleverness, no optimization - just make it work
|
|
45
|
+
3. Run test - it MUST pass
|
|
46
|
+
4. Commit: `feat: implement [feature]`
|
|
47
|
+
|
|
48
|
+
**REFACTOR (if needed):**
|
|
49
|
+
1. Clean up implementation if obvious improvements exist
|
|
50
|
+
2. Run tests - MUST still pass
|
|
51
|
+
3. Only commit if changes made: `refactor: clean up [feature]`
|
|
52
|
+
|
|
53
|
+
**Atomic commits:** Each TDD task produces 2-3 commits following this pattern.
|
|
54
|
+
</execution_flow>
|
|
55
|
+
|
|
56
|
+
<test_quality>
|
|
57
|
+
## Good Tests vs Bad Tests
|
|
58
|
+
|
|
59
|
+
**Test behavior, not implementation:**
|
|
60
|
+
- Good: "returns formatted date string"
|
|
61
|
+
- Bad: "calls formatDate helper with correct params"
|
|
62
|
+
- Tests should survive refactors
|
|
63
|
+
|
|
64
|
+
**One concept per test:**
|
|
65
|
+
- Good: Separate tests for valid input, empty input, malformed input
|
|
66
|
+
- Bad: Single test checking all edge cases with multiple assertions
|
|
67
|
+
|
|
68
|
+
**Descriptive names:**
|
|
69
|
+
- Good: "should reject empty email", "returns null for invalid ID"
|
|
70
|
+
- Bad: "test1", "handles error", "works correctly"
|
|
71
|
+
|
|
72
|
+
**No implementation details:**
|
|
73
|
+
- Good: Test public API, observable behavior
|
|
74
|
+
- Bad: Mock internals, test private methods, assert on internal state
|
|
75
|
+
</test_quality>
|
|
76
|
+
|
|
77
|
+
<framework_setup>
|
|
78
|
+
## Test Framework Setup (If None Exists)
|
|
79
|
+
|
|
80
|
+
When a TDD task exists but no test framework is configured:
|
|
81
|
+
|
|
82
|
+
**1. Detect project type:**
|
|
83
|
+
```bash
|
|
84
|
+
# JavaScript/TypeScript
|
|
85
|
+
if [ -f package.json ]; then echo "node"; fi
|
|
86
|
+
|
|
87
|
+
# Python
|
|
88
|
+
if [ -f requirements.txt ] || [ -f pyproject.toml ]; then echo "python"; fi
|
|
89
|
+
|
|
90
|
+
# Go
|
|
91
|
+
if [ -f go.mod ]; then echo "go"; fi
|
|
92
|
+
|
|
93
|
+
# Rust
|
|
94
|
+
if [ -f Cargo.toml ]; then echo "rust"; fi
|
|
95
|
+
```
|
|
96
|
+
|
|
97
|
+
**2. Install minimal framework:**
|
|
98
|
+
| Project | Framework | Install |
|
|
99
|
+
|---------|-----------|---------|
|
|
100
|
+
| Node.js | Jest | `npm install -D jest @types/jest ts-jest` |
|
|
101
|
+
| Node.js (Vite) | Vitest | `npm install -D vitest` |
|
|
102
|
+
| Python | pytest | `pip install pytest` |
|
|
103
|
+
| Go | testing | Built-in |
|
|
104
|
+
| Rust | cargo test | Built-in |
|
|
105
|
+
|
|
106
|
+
**3. Create config if needed:**
|
|
107
|
+
- Jest: `jest.config.js` with ts-jest preset
|
|
108
|
+
- Vitest: `vitest.config.ts` with test globals
|
|
109
|
+
- pytest: `pytest.ini` or `pyproject.toml` section
|
|
110
|
+
|
|
111
|
+
**4. Verify setup:**
|
|
112
|
+
```bash
|
|
113
|
+
# Run empty test suite - should pass with 0 tests
|
|
114
|
+
npm test # Node
|
|
115
|
+
pytest # Python
|
|
116
|
+
go test ./... # Go
|
|
117
|
+
cargo test # Rust
|
|
118
|
+
```
|
|
119
|
+
|
|
120
|
+
**5. Create first test file:**
|
|
121
|
+
Follow project conventions for test location:
|
|
122
|
+
- `*.test.ts` / `*.spec.ts` next to source
|
|
123
|
+
- `__tests__/` directory
|
|
124
|
+
- `tests/` directory at root
|
|
125
|
+
</framework_setup>
|
|
126
|
+
|
|
127
|
+
<error_handling>
|
|
128
|
+
## Error Handling
|
|
129
|
+
|
|
130
|
+
**Test doesn't fail in RED phase:**
|
|
131
|
+
- Feature may already exist - investigate
|
|
132
|
+
- Test may be wrong (not testing what you think)
|
|
133
|
+
- Fix before proceeding
|
|
134
|
+
|
|
135
|
+
**Test doesn't pass in GREEN phase:**
|
|
136
|
+
- Debug implementation
|
|
137
|
+
- Don't skip to next task
|
|
138
|
+
- Keep iterating until green
|
|
139
|
+
|
|
140
|
+
**Tests fail in REFACTOR phase:**
|
|
141
|
+
- Undo refactor
|
|
142
|
+
- Commit was premature
|
|
143
|
+
- Refactor in smaller steps
|
|
144
|
+
|
|
145
|
+
**Unrelated tests break:**
|
|
146
|
+
- Stop and investigate
|
|
147
|
+
- May indicate coupling issue
|
|
148
|
+
- Fix before proceeding
|
|
149
|
+
</error_handling>
|
|
150
|
+
|
|
151
|
+
<commit_pattern>
|
|
152
|
+
## Commit Pattern for TDD Tasks
|
|
153
|
+
|
|
154
|
+
Each TDD task produces atomic commits:
|
|
155
|
+
|
|
156
|
+
```
|
|
157
|
+
test: add failing test for email validation
|
|
158
|
+
|
|
159
|
+
feat: implement email validation
|
|
160
|
+
|
|
161
|
+
refactor: extract regex to constant (optional)
|
|
162
|
+
```
|
|
163
|
+
|
|
164
|
+
This pattern:
|
|
165
|
+
- Creates clean git history
|
|
166
|
+
- Each commit is independently revertable
|
|
167
|
+
- Shows TDD discipline in commit log
|
|
168
|
+
</commit_pattern>
|
|
@@ -439,6 +439,10 @@ Execute each task in the prompt. **Deviations are normal** - handle them automat
|
|
|
439
439
|
|
|
440
440
|
**If `type="auto"`:**
|
|
441
441
|
|
|
442
|
+
**Before executing:** Check if task has `tdd="true"` attribute:
|
|
443
|
+
- If yes: Follow TDD execution flow (see `<tdd_execution>`) - RED → GREEN → REFACTOR cycle with multiple atomic commits
|
|
444
|
+
- If no: Standard implementation with single commit
|
|
445
|
+
|
|
442
446
|
- Work toward task completion
|
|
443
447
|
- **If CLI/API returns authentication error:** Handle as authentication gate (see below)
|
|
444
448
|
- **When you discover additional work not in plan:** Apply deviation rules (see below) automatically
|
|
@@ -810,6 +814,54 @@ Logged to .planning/ISSUES.md for future consideration:
|
|
|
810
814
|
|
|
811
815
|
</deviation_documentation>
|
|
812
816
|
|
|
817
|
+
<tdd_execution>
|
|
818
|
+
## TDD Task Execution
|
|
819
|
+
|
|
820
|
+
When executing a task with `tdd="true"` attribute:
|
|
821
|
+
|
|
822
|
+
**1. Check test infrastructure:**
|
|
823
|
+
If no test framework configured:
|
|
824
|
+
- Detect project type from package.json/requirements.txt/etc.
|
|
825
|
+
- Install minimal test framework (Jest, pytest, Go testing, etc.)
|
|
826
|
+
- Create test config file
|
|
827
|
+
- Verify: run empty test suite
|
|
828
|
+
|
|
829
|
+
**2. RED - Write failing test:**
|
|
830
|
+
- Read `<test-first>` element for test specification
|
|
831
|
+
- Create test file if doesn't exist (follow project conventions)
|
|
832
|
+
- Write test(s) that describe expected behavior
|
|
833
|
+
- Run tests - MUST fail (if passes, test is wrong or feature exists)
|
|
834
|
+
- Commit: "test: add failing test for [feature]"
|
|
835
|
+
|
|
836
|
+
**3. GREEN - Implement to pass:**
|
|
837
|
+
- Read `<action>` element for implementation guidance
|
|
838
|
+
- Write minimal code to make test pass
|
|
839
|
+
- Run tests - MUST pass
|
|
840
|
+
- Commit: "feat: implement [feature]"
|
|
841
|
+
|
|
842
|
+
**4. REFACTOR (if needed):**
|
|
843
|
+
- Clean up code if obvious improvements
|
|
844
|
+
- Run tests - MUST still pass
|
|
845
|
+
- Commit only if changes made: "refactor: clean up [feature]"
|
|
846
|
+
|
|
847
|
+
**Commit pattern for TDD tasks:**
|
|
848
|
+
Each TDD task produces 2-3 atomic commits:
|
|
849
|
+
1. `test: add failing test for X`
|
|
850
|
+
2. `feat: implement X`
|
|
851
|
+
3. `refactor: clean up X` (optional)
|
|
852
|
+
|
|
853
|
+
**Error handling:**
|
|
854
|
+
- If test doesn't fail in RED phase: Test is wrong or feature already exists. Investigate before proceeding.
|
|
855
|
+
- If test doesn't pass in GREEN phase: Debug implementation, don't skip to next task.
|
|
856
|
+
- If tests fail in REFACTOR phase: Undo refactor, commit was premature.
|
|
857
|
+
|
|
858
|
+
**Verification:**
|
|
859
|
+
After TDD task completion, ensure:
|
|
860
|
+
- All tests pass
|
|
861
|
+
- Test coverage for the new behavior exists
|
|
862
|
+
- No unrelated tests broken
|
|
863
|
+
</tdd_execution>
|
|
864
|
+
|
|
813
865
|
<step name="checkpoint_protocol">
|
|
814
866
|
When encountering `type="checkpoint:*"`:
|
|
815
867
|
|
|
@@ -19,8 +19,9 @@ Decimal phases enable urgent work insertion without renumbering:
|
|
|
19
19
|
2. ~/.claude/get-shit-done/references/plan-format.md
|
|
20
20
|
3. ~/.claude/get-shit-done/references/scope-estimation.md
|
|
21
21
|
4. ~/.claude/get-shit-done/references/checkpoints.md
|
|
22
|
-
5.
|
|
23
|
-
6. .planning/
|
|
22
|
+
5. ~/.claude/get-shit-done/references/tdd.md
|
|
23
|
+
6. .planning/ROADMAP.md
|
|
24
|
+
7. .planning/PROJECT.md
|
|
24
25
|
|
|
25
26
|
**Load domain expertise from ROADMAP:**
|
|
26
27
|
- Parse ROADMAP.md's `## Domain Expertise` section for paths
|
|
@@ -46,7 +47,13 @@ If STATE.md missing but .planning/ exists, offer to reconstruct or continue with
|
|
|
46
47
|
</step>
|
|
47
48
|
|
|
48
49
|
<step name="load_codebase_context">
|
|
49
|
-
Check for
|
|
50
|
+
Check for codebase map:
|
|
51
|
+
|
|
52
|
+
```bash
|
|
53
|
+
ls .planning/codebase/*.md 2>/dev/null
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
**If .planning/codebase/ exists:** Load relevant documents based on phase type:
|
|
50
57
|
|
|
51
58
|
| Phase Keywords | Load These |
|
|
52
59
|
|----------------|------------|
|
|
@@ -63,7 +70,14 @@ Track extracted constraints for PLAN.md context section.
|
|
|
63
70
|
</step>
|
|
64
71
|
|
|
65
72
|
<step name="identify_phase">
|
|
66
|
-
Check roadmap and existing phases
|
|
73
|
+
Check roadmap and existing phases:
|
|
74
|
+
|
|
75
|
+
```bash
|
|
76
|
+
cat .planning/ROADMAP.md
|
|
77
|
+
ls .planning/phases/
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
If multiple phases available, ask which one to plan. If obvious (first incomplete phase), proceed.
|
|
67
81
|
|
|
68
82
|
**Phase number parsing:** Regex `^(\d+)(?:\.(\d+))?$` - Group 1: integer, Group 2: decimal (optional)
|
|
69
83
|
|
|
@@ -112,9 +126,21 @@ For niche domains (3D, games, audio, shaders, ML), suggest `/gsd:research-phase`
|
|
|
112
126
|
<step name="read_project_history">
|
|
113
127
|
**From STATE.md:** Decisions → constrain approach. Deferred issues → candidates. Blockers → may need to address.
|
|
114
128
|
|
|
115
|
-
**From prior summaries:**
|
|
129
|
+
**From prior summaries:**
|
|
130
|
+
|
|
131
|
+
```bash
|
|
132
|
+
ls .planning/phases/*/*-SUMMARY.md 2>/dev/null | sort
|
|
133
|
+
```
|
|
134
|
+
|
|
135
|
+
Scan for decisions constraining this phase, issues flagged for "later", warnings in "Next Phase Readiness", patterns to maintain.
|
|
116
136
|
|
|
117
|
-
**From ISSUES.md:**
|
|
137
|
+
**From ISSUES.md:**
|
|
138
|
+
|
|
139
|
+
```bash
|
|
140
|
+
cat .planning/ISSUES.md 2>/dev/null
|
|
141
|
+
```
|
|
142
|
+
|
|
143
|
+
Assess each open issue - relevant to this phase? Waiting long enough? Natural to address now? Blocking something?
|
|
118
144
|
|
|
119
145
|
**Answer before proceeding:**
|
|
120
146
|
- Q1: What decisions from previous phases constrain this phase?
|
|
@@ -134,6 +160,18 @@ Understand:
|
|
|
134
160
|
- Any DISCOVERY.md (from mandatory discovery)
|
|
135
161
|
- Any {phase}-CONTEXT.md (from /gsd:discuss-phase)
|
|
136
162
|
|
|
163
|
+
```bash
|
|
164
|
+
# If mid-project, understand current state
|
|
165
|
+
ls -la src/ 2>/dev/null
|
|
166
|
+
cat package.json 2>/dev/null | head -20
|
|
167
|
+
|
|
168
|
+
# Check for ecosystem research (from /gsd:research-phase)
|
|
169
|
+
cat .planning/phases/XX-name/${PHASE}-RESEARCH.md 2>/dev/null
|
|
170
|
+
|
|
171
|
+
# Check for phase context (from /gsd:discuss-phase)
|
|
172
|
+
cat .planning/phases/XX-name/${PHASE}-CONTEXT.md 2>/dev/null
|
|
173
|
+
```
|
|
174
|
+
|
|
137
175
|
**If RESEARCH.md exists:** Use standard_stack (these libraries), architecture_patterns (follow in task structure), dont_hand_roll (NEVER custom solutions for listed problems), common_pitfalls (inform verification), code_examples (reference in actions).
|
|
138
176
|
|
|
139
177
|
**If CONTEXT.md exists:** Honor vision, prioritize essential, respect boundaries, incorporate specifics.
|
|
@@ -150,7 +188,33 @@ Decompose phase into tasks. Each task needs:
|
|
|
150
188
|
- **Verify**: How to prove it worked
|
|
151
189
|
- **Done**: Acceptance criteria
|
|
152
190
|
|
|
153
|
-
**TDD
|
|
191
|
+
**TDD detection:** For each task, evaluate TDD fit:
|
|
192
|
+
|
|
193
|
+
TDD candidates (add `tdd="true"` to task, include `<test-first>` element):
|
|
194
|
+
- Business logic with defined inputs/outputs
|
|
195
|
+
- API endpoints with request/response contracts
|
|
196
|
+
- Data transformations, parsing, formatting
|
|
197
|
+
- Validation rules and constraints
|
|
198
|
+
- Algorithms with testable behavior
|
|
199
|
+
- State machines and workflows
|
|
200
|
+
|
|
201
|
+
Skip TDD (standard `type="auto"` task):
|
|
202
|
+
- UI layout, styling, visual components
|
|
203
|
+
- Configuration changes
|
|
204
|
+
- Glue code connecting existing components
|
|
205
|
+
- One-off scripts and migrations
|
|
206
|
+
- Simple CRUD with no business logic
|
|
207
|
+
|
|
208
|
+
**Heuristic:** Can you write `expect(fn(input)).toBe(output)` before writing `fn`?
|
|
209
|
+
→ Yes: Add `tdd="true"`, include `<test-first>` describing the failing test
|
|
210
|
+
→ No: Standard task, no TDD annotation
|
|
211
|
+
|
|
212
|
+
**Test framework:** If project has no test setup and TDD tasks exist, add a setup task first:
|
|
213
|
+
- Detect project type (package.json → Jest, requirements.txt → pytest, etc.)
|
|
214
|
+
- Add minimal test configuration
|
|
215
|
+
- Create example test file to verify setup
|
|
216
|
+
|
|
217
|
+
See `~/.claude/get-shit-done/references/tdd.md` for complete TDD guidance.
|
|
154
218
|
|
|
155
219
|
**Checkpoints:** Visual/functional verification → checkpoint:human-verify. Implementation choices → checkpoint:decision. Manual action (email, 2FA) → checkpoint:human-action (rare).
|
|
156
220
|
|
|
@@ -201,15 +265,6 @@ Wait for confirmation. If "adjust": revise. If "start over": return to gather_ph
|
|
|
201
265
|
</if>
|
|
202
266
|
</step>
|
|
203
267
|
|
|
204
|
-
<step name="decision_gate">
|
|
205
|
-
<if mode="yolo">Auto-approve and proceed.</if>
|
|
206
|
-
<if mode="interactive">
|
|
207
|
-
Ask: "Ready to create the phase prompt, or ask more questions?"
|
|
208
|
-
Options: Create phase prompt / Ask more questions / Let me add context
|
|
209
|
-
Loop until "Create phase prompt" selected.
|
|
210
|
-
</if>
|
|
211
|
-
</step>
|
|
212
|
-
|
|
213
268
|
<step name="write_phase_prompt">
|
|
214
269
|
Use template from `~/.claude/get-shit-done/templates/phase-prompt.md`.
|
|
215
270
|
|
|
@@ -264,6 +319,21 @@ Phase plan created: .planning/phases/XX-name/{phase}-01-PLAN.md
|
|
|
264
319
|
- "Set up authentication" / "Make it secure" / "Handle edge cases"
|
|
265
320
|
|
|
266
321
|
If you can't specify Files + Action + Verify + Done, the task is too vague.
|
|
322
|
+
|
|
323
|
+
**Good TDD task:**
|
|
324
|
+
```xml
|
|
325
|
+
<task type="auto" tdd="true">
|
|
326
|
+
<name>Create price calculator with discount rules</name>
|
|
327
|
+
<files>src/lib/pricing.ts, src/lib/pricing.test.ts</files>
|
|
328
|
+
<test-first>
|
|
329
|
+
Test: calculatePrice applies discounts correctly
|
|
330
|
+
Cases: base 100 + 10% off → 90, base 100 + 20% off + $5 coupon → 75
|
|
331
|
+
</test-first>
|
|
332
|
+
<action>Implement calculatePrice(base, discountPercent, couponAmount). Apply percentage first, then flat amount.</action>
|
|
333
|
+
<verify>npm test -- pricing.test.ts passes</verify>
|
|
334
|
+
<done>Price calculation handles all discount combinations correctly</done>
|
|
335
|
+
</task>
|
|
336
|
+
```
|
|
267
337
|
</task_quality>
|
|
268
338
|
|
|
269
339
|
<anti_patterns>
|
package/package.json
CHANGED