@gobing-ai/spur 0.2.5 → 0.2.9
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/package.json +8 -11
- package/schemas/section-matrix.schema.json +68 -0
- package/schemas/spur-config.schema.json +71 -1
- package/schemas/state-machine-workflow.schema.json +4 -0
- package/schemas/task-batch.schema.json +53 -0
- package/spur-cli/config/config.example.yaml +25 -1
- package/spur-cli/config/rules/boundary/config-loading-ownership.yaml +54 -0
- package/spur-cli/config/rules/boundary/planning-folder-hardcode.yaml +46 -0
- package/spur-cli/config/rules/recommended-pre-check.yaml +3 -2
- package/spur-cli/config/rules/structure/test-location.yaml +10 -0
- package/spur-cli/config/rules/typescript/happy-dom-teardown.yaml +43 -0
- package/spur-cli/config/rules/typescript/no-leaky-module-mocks.yaml +71 -0
- package/spur-cli/config/rules/ui/ui-import-boundary.yaml +51 -0
- package/spur-cli/config/tasks/section-matrix.yaml +190 -0
- package/spur-cli/config/tasks/templates/brainstorm.md +29 -0
- package/spur-cli/config/tasks/templates/feature-impl.md +50 -0
- package/spur-cli/config/tasks/templates/issue.md +33 -0
- package/spur-cli/config/tasks/templates/meta.md +31 -0
- package/spur-cli/config/tasks/templates/review.md +53 -0
- package/spur-cli/config/tasks/templates/standard.md +48 -0
- package/spur-cli/config/templates/bdd/checklist.md +1 -0
- package/spur-cli/config/templates/bdd/gherkin.md +8 -0
- package/spur-cli/config/templates/docs/00_ADR.md +27 -0
- package/spur-cli/config/templates/docs/01_PRD.md +37 -0
- package/spur-cli/config/templates/docs/02_ROADMAP.md +22 -0
- package/spur-cli/config/templates/docs/03_ARCHITECTURE.md +27 -0
- package/spur-cli/config/templates/docs/04_DESIGN.md +30 -0
- package/spur-cli/config/templates/docs/05_FEATURES.md +23 -0
- package/spur-cli/config/templates/docs/99_PROJECT_CONSTITUTION.md +65 -0
- package/spur-cli/config/templates/feature/default.md +41 -0
- package/spur-cli/config/templates/task/brainstorm.md +29 -0
- package/spur-cli/config/templates/task/feature-impl.md +50 -0
- package/spur-cli/config/templates/task/issue.md +33 -0
- package/spur-cli/config/templates/task/meta.md +31 -0
- package/spur-cli/config/templates/task/review.md +52 -0
- package/spur-cli/config/templates/task/standard.md +48 -0
- package/spur-cli/config/workflows/feature-dev.yaml +92 -80
- package/spur-cli/config/workflows/feature-lifecycle.yaml +100 -0
- package/spur-cli/config/workflows/planning-pipeline.yaml +166 -0
- package/spur-cli/config/workflows/task-lifecycle.yaml +128 -0
- package/spur-cli/config/workflows/task-pipeline.yaml +244 -0
- package/spur.js +69485 -52365
|
@@ -0,0 +1,190 @@
|
|
|
1
|
+
# Section-Status-Matrix: which sections are required/optional/forbidden per task status.
|
|
2
|
+
# Design §3.2 — evaluated CLI-side only. Ships permissive; tightened by compliance data.
|
|
3
|
+
#
|
|
4
|
+
# Each VARIANT (the unified template axis — TASK_VARIANTS) maps status →
|
|
5
|
+
# { required, optional, forbidden } section lists. Sections reference the canonical
|
|
6
|
+
# section vocabulary (§2.1). `gate: true` on a status makes L2 violations hard errors.
|
|
7
|
+
#
|
|
8
|
+
# The variant is selected by a task's `template:` frontmatter (default: `standard`).
|
|
9
|
+
# It drives BOTH validation (`spur task check`) AND creation (`buildTaskSkeleton`).
|
|
10
|
+
$schema: "@gobing-ai/spur/schemas/section-matrix.schema.json"
|
|
11
|
+
|
|
12
|
+
variants:
|
|
13
|
+
# Workhorse general-purpose task.
|
|
14
|
+
standard:
|
|
15
|
+
backlog:
|
|
16
|
+
required: [Background]
|
|
17
|
+
forbidden: [Solution, Review, Testing]
|
|
18
|
+
# todo = "ready to execute" (§2.3): fully specified and HITL-reviewable.
|
|
19
|
+
# Design + Plan + Acceptance Criteria are required so a task can be reviewed
|
|
20
|
+
# and approved before any code is written. Solution stays forbidden — it is
|
|
21
|
+
# the implementation change-map (file:line), authored at wip/testing.
|
|
22
|
+
todo:
|
|
23
|
+
required: [Background, Acceptance Criteria, Design, Plan]
|
|
24
|
+
optional: [Q&A, Requirements]
|
|
25
|
+
forbidden: [Solution, Review, Testing]
|
|
26
|
+
wip:
|
|
27
|
+
required: [Background, Acceptance Criteria, Design, Plan]
|
|
28
|
+
optional: [Q&A, Requirements, Solution]
|
|
29
|
+
forbidden: [Review]
|
|
30
|
+
testing:
|
|
31
|
+
required: [Solution, Testing]
|
|
32
|
+
optional: [Background, Review]
|
|
33
|
+
# done REQUIRES the evidence trio (Solution/Testing/Review). The spec sections
|
|
34
|
+
# a task was built from (Design/Plan/AC/…) are OPTIONAL, not forbidden, so a
|
|
35
|
+
# finished task keeps its design history rather than being stripped to pass the
|
|
36
|
+
# closed-world gate. gate:true still hard-fails a missing required section.
|
|
37
|
+
done:
|
|
38
|
+
required: [Solution, Testing, Review]
|
|
39
|
+
optional: [Background, Requirements, Acceptance Criteria, Q&A, Design, Plan]
|
|
40
|
+
gate: true
|
|
41
|
+
blocked:
|
|
42
|
+
required: [Background]
|
|
43
|
+
optional: [Plan, Solution]
|
|
44
|
+
cancelled:
|
|
45
|
+
required: []
|
|
46
|
+
optional: [Background]
|
|
47
|
+
|
|
48
|
+
# Feature implementation — AC pre-seeded from the linked feature's scenarios.
|
|
49
|
+
feature-impl:
|
|
50
|
+
backlog:
|
|
51
|
+
required: [Background]
|
|
52
|
+
forbidden: [Solution, Review, Testing]
|
|
53
|
+
todo:
|
|
54
|
+
required: [Background, Acceptance Criteria, Design, Plan]
|
|
55
|
+
optional: [Q&A, Requirements]
|
|
56
|
+
forbidden: [Solution, Review, Testing]
|
|
57
|
+
wip:
|
|
58
|
+
required: [Background, Acceptance Criteria, Design, Plan]
|
|
59
|
+
optional: [Q&A, Requirements, Solution]
|
|
60
|
+
forbidden: [Review]
|
|
61
|
+
testing:
|
|
62
|
+
required: [Solution, Testing]
|
|
63
|
+
optional: [Background, Requirements, Acceptance Criteria, Design, Plan, Review]
|
|
64
|
+
# done keeps the spec sections optional (see `standard` rationale above) so a
|
|
65
|
+
# finished feature-impl task retains its Design/Plan/AC history.
|
|
66
|
+
done:
|
|
67
|
+
required: [Solution, Testing, Review]
|
|
68
|
+
optional: [Background, Requirements, Acceptance Criteria, Q&A, Design, Plan]
|
|
69
|
+
gate: true
|
|
70
|
+
blocked:
|
|
71
|
+
required: [Background]
|
|
72
|
+
optional: [Plan, Solution]
|
|
73
|
+
cancelled:
|
|
74
|
+
required: []
|
|
75
|
+
optional: [Background]
|
|
76
|
+
|
|
77
|
+
# Bug / issue report — repro in Background, verified Root Cause, then fix.
|
|
78
|
+
issue:
|
|
79
|
+
backlog:
|
|
80
|
+
required: [Background]
|
|
81
|
+
forbidden: [Solution, Review]
|
|
82
|
+
todo:
|
|
83
|
+
required: [Background, Root Cause, Plan]
|
|
84
|
+
optional: [Acceptance Criteria, Design, Q&A]
|
|
85
|
+
forbidden: [Solution, Review]
|
|
86
|
+
wip:
|
|
87
|
+
required: [Background, Root Cause, Plan]
|
|
88
|
+
optional: [Design, Solution, Q&A]
|
|
89
|
+
forbidden: [Review]
|
|
90
|
+
testing:
|
|
91
|
+
required: [Root Cause, Solution, Testing]
|
|
92
|
+
optional: [Background, Review]
|
|
93
|
+
done:
|
|
94
|
+
required: [Root Cause, Solution, Testing, Review]
|
|
95
|
+
optional: [Background, Acceptance Criteria, Design, Plan, Q&A]
|
|
96
|
+
gate: true
|
|
97
|
+
blocked:
|
|
98
|
+
required: [Background]
|
|
99
|
+
optional: [Root Cause, Plan]
|
|
100
|
+
cancelled:
|
|
101
|
+
required: []
|
|
102
|
+
optional: [Background]
|
|
103
|
+
|
|
104
|
+
# Code-review result task — the deliverable is the P1–P4 findings table.
|
|
105
|
+
#
|
|
106
|
+
# The review template scaffolds Background (with #### Review Findings sub-section),
|
|
107
|
+
# Plan (checklist), and Review (forward reference for post-implementation reflection).
|
|
108
|
+
# Plan and Review are optional at backlog/todo so the template renders cleanly;
|
|
109
|
+
# Review becomes required at wip+.
|
|
110
|
+
#
|
|
111
|
+
# Requirements is optional from todo onward (the authoring stage where a refined
|
|
112
|
+
# review-findings task gains scoped requirements); Solution and Testing are optional
|
|
113
|
+
# at wip+ — none required, but tolerated so that a review-findings task that evolves
|
|
114
|
+
# into implementation work (the common dogfood follow-up path) can carry scoped
|
|
115
|
+
# requirements, a change-map, and coverage data without matrix violations.
|
|
116
|
+
# The required list guards the real deliverables; optional is permissive on purpose.
|
|
117
|
+
review:
|
|
118
|
+
backlog:
|
|
119
|
+
required: [Background]
|
|
120
|
+
optional: [Plan, Review]
|
|
121
|
+
forbidden: [Testing]
|
|
122
|
+
todo:
|
|
123
|
+
required: [Background, Plan]
|
|
124
|
+
optional: [Q&A, Requirements, Review]
|
|
125
|
+
forbidden: [Testing]
|
|
126
|
+
wip:
|
|
127
|
+
required: [Background, Review]
|
|
128
|
+
optional: [Plan, Q&A, Requirements, Solution, Testing]
|
|
129
|
+
testing:
|
|
130
|
+
required: [Background, Review]
|
|
131
|
+
optional: [Plan, Requirements, Solution, Testing]
|
|
132
|
+
done:
|
|
133
|
+
required: [Background, Review]
|
|
134
|
+
optional: [Plan, Q&A, Requirements, Solution, Testing]
|
|
135
|
+
gate: true
|
|
136
|
+
blocked:
|
|
137
|
+
required: [Background]
|
|
138
|
+
optional: [Plan, Review, Solution]
|
|
139
|
+
cancelled:
|
|
140
|
+
required: []
|
|
141
|
+
optional: [Background]
|
|
142
|
+
|
|
143
|
+
# Process / docs / chore — lightweight: Background + Plan, no Solution/AC gate.
|
|
144
|
+
meta:
|
|
145
|
+
backlog:
|
|
146
|
+
required: [Background]
|
|
147
|
+
forbidden: [Review]
|
|
148
|
+
todo:
|
|
149
|
+
required: [Background, Plan]
|
|
150
|
+
optional: [Q&A, Design]
|
|
151
|
+
forbidden: [Review]
|
|
152
|
+
wip:
|
|
153
|
+
required: [Background, Plan]
|
|
154
|
+
optional: [Q&A, Design, Solution]
|
|
155
|
+
forbidden: [Review]
|
|
156
|
+
testing:
|
|
157
|
+
required: [Background, Plan]
|
|
158
|
+
optional: [Solution, Testing]
|
|
159
|
+
done:
|
|
160
|
+
required: [Background, Plan]
|
|
161
|
+
optional: [Solution, Testing, Review]
|
|
162
|
+
blocked:
|
|
163
|
+
required: [Background]
|
|
164
|
+
optional: [Plan]
|
|
165
|
+
cancelled:
|
|
166
|
+
required: []
|
|
167
|
+
optional: [Background]
|
|
168
|
+
|
|
169
|
+
# Brainstorm template (minimal idea capture).
|
|
170
|
+
brainstorm:
|
|
171
|
+
backlog:
|
|
172
|
+
required: [Background]
|
|
173
|
+
forbidden: [Solution, Review, Testing]
|
|
174
|
+
todo:
|
|
175
|
+
required: [Background]
|
|
176
|
+
optional: [Q&A]
|
|
177
|
+
wip:
|
|
178
|
+
required: [Background, Plan]
|
|
179
|
+
optional: [Q&A, Design]
|
|
180
|
+
forbidden: [Review]
|
|
181
|
+
testing:
|
|
182
|
+
required: [Background, Solution]
|
|
183
|
+
optional: [Testing]
|
|
184
|
+
forbidden: [Review]
|
|
185
|
+
done:
|
|
186
|
+
required: [Background, Solution]
|
|
187
|
+
blocked:
|
|
188
|
+
required: [Background]
|
|
189
|
+
cancelled:
|
|
190
|
+
required: []
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
---
|
|
2
|
+
schema_version: 1
|
|
3
|
+
name: "{{ NAME }}"
|
|
4
|
+
description: ""
|
|
5
|
+
status: backlog
|
|
6
|
+
type: brainstorm
|
|
7
|
+
profile: standard
|
|
8
|
+
feature_id: null
|
|
9
|
+
parent_wbs: null
|
|
10
|
+
priority: P2
|
|
11
|
+
tags: []
|
|
12
|
+
dependencies: []
|
|
13
|
+
created_at: "{{ CREATED_AT }}"
|
|
14
|
+
updated_at: "{{ CREATED_AT }}"
|
|
15
|
+
---
|
|
16
|
+
|
|
17
|
+
## {{ WBS }}. {{ NAME }}
|
|
18
|
+
|
|
19
|
+
### Background
|
|
20
|
+
|
|
21
|
+
{{ BACKGROUND }}
|
|
22
|
+
|
|
23
|
+
### Q&A
|
|
24
|
+
|
|
25
|
+
### Plan
|
|
26
|
+
|
|
27
|
+
### References
|
|
28
|
+
|
|
29
|
+
### History
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
---
|
|
2
|
+
schema_version: 1
|
|
3
|
+
name: "{{ NAME }}"
|
|
4
|
+
description: ""
|
|
5
|
+
status: backlog
|
|
6
|
+
type: task
|
|
7
|
+
profile: standard
|
|
8
|
+
feature_id: null
|
|
9
|
+
parent_wbs: null
|
|
10
|
+
priority: P2
|
|
11
|
+
tags: []
|
|
12
|
+
dependencies: []
|
|
13
|
+
created_at: "{{ CREATED_AT }}"
|
|
14
|
+
updated_at: "{{ CREATED_AT }}"
|
|
15
|
+
---
|
|
16
|
+
|
|
17
|
+
## {{ WBS }}. {{ NAME }}
|
|
18
|
+
|
|
19
|
+
### Background
|
|
20
|
+
|
|
21
|
+
{{ BACKGROUND }}
|
|
22
|
+
|
|
23
|
+
### Acceptance Criteria
|
|
24
|
+
|
|
25
|
+
```gherkin
|
|
26
|
+
Feature: {{ NAME }}
|
|
27
|
+
|
|
28
|
+
Scenario: Basic acceptance
|
|
29
|
+
Given a precondition
|
|
30
|
+
When an action is taken
|
|
31
|
+
Then an expected result occurs
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
- [ ] Acceptance checklist item
|
|
35
|
+
|
|
36
|
+
### Design
|
|
37
|
+
|
|
38
|
+
### Plan
|
|
39
|
+
|
|
40
|
+
- [ ] Implementation step
|
|
41
|
+
|
|
42
|
+
### Solution
|
|
43
|
+
|
|
44
|
+
### Testing
|
|
45
|
+
|
|
46
|
+
### Review
|
|
47
|
+
|
|
48
|
+
### References
|
|
49
|
+
|
|
50
|
+
### History
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
---
|
|
2
|
+
schema_version: 1
|
|
3
|
+
name: "{{ NAME }}"
|
|
4
|
+
description: ""
|
|
5
|
+
status: backlog
|
|
6
|
+
type: issue
|
|
7
|
+
profile: standard
|
|
8
|
+
feature_id: null
|
|
9
|
+
parent_wbs: null
|
|
10
|
+
priority: P2
|
|
11
|
+
tags: ["bug"]
|
|
12
|
+
dependencies: []
|
|
13
|
+
created_at: "{{ CREATED_AT }}"
|
|
14
|
+
updated_at: "{{ CREATED_AT }}"
|
|
15
|
+
---
|
|
16
|
+
|
|
17
|
+
## {{ WBS }}. {{ NAME }}
|
|
18
|
+
|
|
19
|
+
### Background
|
|
20
|
+
|
|
21
|
+
{{ BACKGROUND }}
|
|
22
|
+
|
|
23
|
+
### Root Cause
|
|
24
|
+
|
|
25
|
+
### Solution
|
|
26
|
+
|
|
27
|
+
### Testing
|
|
28
|
+
|
|
29
|
+
### Review
|
|
30
|
+
|
|
31
|
+
### References
|
|
32
|
+
|
|
33
|
+
### History
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
---
|
|
2
|
+
schema_version: 1
|
|
3
|
+
name: "{{ NAME }}"
|
|
4
|
+
description: ""
|
|
5
|
+
status: backlog
|
|
6
|
+
type: meta
|
|
7
|
+
profile: standard
|
|
8
|
+
feature_id: null
|
|
9
|
+
parent_wbs: null
|
|
10
|
+
priority: P2
|
|
11
|
+
tags: ["meta"]
|
|
12
|
+
dependencies: []
|
|
13
|
+
created_at: "{{ CREATED_AT }}"
|
|
14
|
+
updated_at: "{{ CREATED_AT }}"
|
|
15
|
+
---
|
|
16
|
+
|
|
17
|
+
## {{ WBS }}. {{ NAME }}
|
|
18
|
+
|
|
19
|
+
### Background
|
|
20
|
+
|
|
21
|
+
{{ BACKGROUND }}
|
|
22
|
+
|
|
23
|
+
### Plan
|
|
24
|
+
|
|
25
|
+
- [ ] Implementation step
|
|
26
|
+
|
|
27
|
+
### Testing
|
|
28
|
+
|
|
29
|
+
### References
|
|
30
|
+
|
|
31
|
+
### History
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
---
|
|
2
|
+
schema_version: 1
|
|
3
|
+
name: "{{ NAME }}"
|
|
4
|
+
description: ""
|
|
5
|
+
status: backlog
|
|
6
|
+
type: review
|
|
7
|
+
template: review
|
|
8
|
+
profile: standard
|
|
9
|
+
feature_id: null
|
|
10
|
+
parent_wbs: null
|
|
11
|
+
priority: P2
|
|
12
|
+
tags: ["review"]
|
|
13
|
+
dependencies: []
|
|
14
|
+
created_at: "{{ CREATED_AT }}"
|
|
15
|
+
updated_at: "{{ CREATED_AT }}"
|
|
16
|
+
---
|
|
17
|
+
|
|
18
|
+
## {{ WBS }}. {{ NAME }}
|
|
19
|
+
|
|
20
|
+
### Background
|
|
21
|
+
|
|
22
|
+
{{ BACKGROUND }}
|
|
23
|
+
|
|
24
|
+
#### Review Findings
|
|
25
|
+
|
|
26
|
+
The code-review findings this task must address — logged here as **input** (what was found
|
|
27
|
+
in the reviewed PR/commit/diff). Fix in priority order (P1 → P2 → …); re-review after.
|
|
28
|
+
|
|
29
|
+
| Severity | File | Finding | Recommendation |
|
|
30
|
+
| -------- | ---- | ------- | -------------- |
|
|
31
|
+
| P1 | | | |
|
|
32
|
+
| P2 | | | |
|
|
33
|
+
|
|
34
|
+
### Plan
|
|
35
|
+
|
|
36
|
+
- [ ] Fix P1 findings
|
|
37
|
+
- [ ] Fix P2 findings
|
|
38
|
+
- [ ] Fix all the remaining findings if any
|
|
39
|
+
- [ ] Re-review the changed code
|
|
40
|
+
|
|
41
|
+
### Review
|
|
42
|
+
|
|
43
|
+
Post-implementation reflection — filled **after** the first fix round: what went wrong, what
|
|
44
|
+
remains to fix before closing, and any **back-issues** (new findings surfaced by the fix).
|
|
45
|
+
|
|
46
|
+
| Severity | File | Finding | Recommendation |
|
|
47
|
+
| -------- | ---- | ------- | -------------- |
|
|
48
|
+
| P1 | | | |
|
|
49
|
+
| P2 | | | |
|
|
50
|
+
|
|
51
|
+
### References
|
|
52
|
+
|
|
53
|
+
### History
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
---
|
|
2
|
+
schema_version: 1
|
|
3
|
+
name: "{{ NAME }}"
|
|
4
|
+
description: ""
|
|
5
|
+
status: backlog
|
|
6
|
+
type: task
|
|
7
|
+
profile: standard
|
|
8
|
+
feature_id: null
|
|
9
|
+
parent_wbs: null
|
|
10
|
+
priority: P2
|
|
11
|
+
tags: []
|
|
12
|
+
dependencies: []
|
|
13
|
+
created_at: "{{ CREATED_AT }}"
|
|
14
|
+
updated_at: "{{ CREATED_AT }}"
|
|
15
|
+
---
|
|
16
|
+
|
|
17
|
+
## {{ WBS }}. {{ NAME }}
|
|
18
|
+
|
|
19
|
+
### Background
|
|
20
|
+
|
|
21
|
+
{{ BACKGROUND }}
|
|
22
|
+
|
|
23
|
+
### Acceptance Criteria
|
|
24
|
+
|
|
25
|
+
```gherkin
|
|
26
|
+
Feature: {{ NAME }}
|
|
27
|
+
|
|
28
|
+
Scenario: Basic acceptance
|
|
29
|
+
Given a precondition
|
|
30
|
+
When an action is taken
|
|
31
|
+
Then an expected result occurs
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
- [ ] Acceptance checklist item
|
|
35
|
+
|
|
36
|
+
### Plan
|
|
37
|
+
|
|
38
|
+
- [ ] Implementation step
|
|
39
|
+
|
|
40
|
+
### Solution
|
|
41
|
+
|
|
42
|
+
### Testing
|
|
43
|
+
|
|
44
|
+
### Review
|
|
45
|
+
|
|
46
|
+
### References
|
|
47
|
+
|
|
48
|
+
### History
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
- [ ] {{ CHECKLIST_ITEM }}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: Architecture Decision Records
|
|
3
|
+
doc: 00_ADR
|
|
4
|
+
owns: WHY — which cross-cutting decision was made, and the one-line reason
|
|
5
|
+
authority: authoritative
|
|
6
|
+
version: 1.0.0
|
|
7
|
+
created_at: 1970-01-01T00:00:00.000Z
|
|
8
|
+
updated_at: 1970-01-01T00:00:00.000Z
|
|
9
|
+
---
|
|
10
|
+
|
|
11
|
+
# Architecture Decision Records
|
|
12
|
+
|
|
13
|
+
> Authoritative on **decisions**. Lower number wins — this doc overrides all others on decisions.
|
|
14
|
+
> Each entry is append-only; supersession is by a new dated entry, never by editing an old one.
|
|
15
|
+
|
|
16
|
+
## ADR-001 — (example) Adopt this doc structure
|
|
17
|
+
|
|
18
|
+
- **Date:** 1970-01-01
|
|
19
|
+
- **Status:** accepted
|
|
20
|
+
- **Context:** Project needs a single source of truth for decisions and scope.
|
|
21
|
+
- **Decision:** Adopt the Spur doc structure (`00`–`05` + `99` constitution).
|
|
22
|
+
- **Reason:** Separates WHY (`00`) from WHAT (`01`) from HOW (`03`/`04`) — one fact, one home.
|
|
23
|
+
|
|
24
|
+
<!--
|
|
25
|
+
Add new ADRs here. Copy the entry shape above (Date, Status, Context, Decision, Reason).
|
|
26
|
+
A decision that reverses a prior ADR adds a new entry that says "supersedes ADR-NNN".
|
|
27
|
+
-->
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: Product Requirements Document
|
|
3
|
+
doc: 01_PRD
|
|
4
|
+
owns: WHAT — product vision, users, scope (in / out / deferred)
|
|
5
|
+
authority: authoritative-on-scope
|
|
6
|
+
version: 1.0.0
|
|
7
|
+
created_at: 1970-01-01T00:00:00.000Z
|
|
8
|
+
updated_at: 1970-01-01T00:00:00.000Z
|
|
9
|
+
---
|
|
10
|
+
|
|
11
|
+
# Product Requirements Document
|
|
12
|
+
|
|
13
|
+
> Authoritative on **scope**. In-scope vs out-of-scope vs deferred lives here and nowhere else.
|
|
14
|
+
|
|
15
|
+
## 1. Vision
|
|
16
|
+
|
|
17
|
+
_(One sentence: what this product is and who it is for.)_
|
|
18
|
+
|
|
19
|
+
## 2. Users
|
|
20
|
+
|
|
21
|
+
| User | Primary need |
|
|
22
|
+
|------|-------------|
|
|
23
|
+
| _(user persona)_ | _(their primary need)_ |
|
|
24
|
+
|
|
25
|
+
## 3. Scope
|
|
26
|
+
|
|
27
|
+
### In scope
|
|
28
|
+
|
|
29
|
+
- _(capability the product delivers)_
|
|
30
|
+
|
|
31
|
+
### Out of scope
|
|
32
|
+
|
|
33
|
+
- _(explicitly excluded capability — prevents scope creep)_
|
|
34
|
+
|
|
35
|
+
### Deferred
|
|
36
|
+
|
|
37
|
+
- _(capability intentionally postponed — not a commitment)_
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: Roadmap
|
|
3
|
+
doc: 02_ROADMAP
|
|
4
|
+
owns: WHEN — phases, current vs deferred, sequencing
|
|
5
|
+
authority: derived
|
|
6
|
+
version: 1.0.0
|
|
7
|
+
created_at: 1970-01-01T00:00:00.000Z
|
|
8
|
+
updated_at: 1970-01-01T00:00:00.000Z
|
|
9
|
+
---
|
|
10
|
+
|
|
11
|
+
# Roadmap
|
|
12
|
+
|
|
13
|
+
> Derived from `01_PRD` (scope) and `00_ADR` (decisions). Edit when phase status changes.
|
|
14
|
+
|
|
15
|
+
## Phases
|
|
16
|
+
|
|
17
|
+
| Phase | Status | Items |
|
|
18
|
+
|-------|--------|-------|
|
|
19
|
+
| Phase 0 — Foundation | ✅ done | _(list the real, shipped deliverable names)_ |
|
|
20
|
+
| Phase 1 — _(name)_ | ⏳ planned | _(items)_ |
|
|
21
|
+
|
|
22
|
+
**Status legend:** ✅ done · 🔶 partial · ⏳ planned · 💤 deferred
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: Architecture
|
|
3
|
+
doc: 03_ARCHITECTURE
|
|
4
|
+
owns: HOW — module boundaries, data flow, runtime model, invariants
|
|
5
|
+
authority: derived
|
|
6
|
+
version: 1.0.0
|
|
7
|
+
created_at: 1970-01-01T00:00:00.000Z
|
|
8
|
+
updated_at: 1970-01-01T00:00:00.000Z
|
|
9
|
+
---
|
|
10
|
+
|
|
11
|
+
# Architecture
|
|
12
|
+
|
|
13
|
+
> Derived (ADR wins). Read before cross-module/seam/schema work; edit when boundaries or mechanisms change.
|
|
14
|
+
|
|
15
|
+
## 1. Module map
|
|
16
|
+
|
|
17
|
+
```
|
|
18
|
+
_(ascii tree or diagram of the major modules and their boundaries)_
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
## 2. Data flow
|
|
22
|
+
|
|
23
|
+
_(Describe the primary data path: input → processing → output. Name the seams.)_
|
|
24
|
+
|
|
25
|
+
## 3. Invariants
|
|
26
|
+
|
|
27
|
+
- _(state or property that always holds — the thing tests should protect)_
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: Design
|
|
3
|
+
doc: 04_DESIGN
|
|
4
|
+
owns: SURFACE — concrete shapes: every CLI command, flag, config key, env var, table, DTO
|
|
5
|
+
authority: derived
|
|
6
|
+
version: 1.0.0
|
|
7
|
+
created_at: 1970-01-01T00:00:00.000Z
|
|
8
|
+
updated_at: 1970-01-01T00:00:00.000Z
|
|
9
|
+
---
|
|
10
|
+
|
|
11
|
+
# Design
|
|
12
|
+
|
|
13
|
+
> Derived. Concrete shapes — every command, flag, config key, env var, schema, and DTO. Edit when
|
|
14
|
+
> a surface changes.
|
|
15
|
+
|
|
16
|
+
## 1. CLI commands
|
|
17
|
+
|
|
18
|
+
```
|
|
19
|
+
_(command) <positional> [--flag <value>] [--json]
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
| Command | Description |
|
|
23
|
+
|---------|-------------|
|
|
24
|
+
| _(command)_ | _(one-line description)_ |
|
|
25
|
+
|
|
26
|
+
## 2. Configuration keys
|
|
27
|
+
|
|
28
|
+
| Key | Type | Default | Description |
|
|
29
|
+
|-----|------|---------|-------------|
|
|
30
|
+
| _(key)_ | _(type)_ | _(default)_ | _(description)_ |
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: Features
|
|
3
|
+
doc: 05_FEATURES
|
|
4
|
+
owns: STATUS — feature decomposition + state
|
|
5
|
+
authority: derived
|
|
6
|
+
version: 1.0.0
|
|
7
|
+
created_at: 1970-01-01T00:00:00.000Z
|
|
8
|
+
updated_at: 1970-01-01T00:00:00.000Z
|
|
9
|
+
---
|
|
10
|
+
|
|
11
|
+
# Features
|
|
12
|
+
|
|
13
|
+
> Derived. Feature status roll-up. Edit when a feature's status changes.
|
|
14
|
+
|
|
15
|
+
## Status legend
|
|
16
|
+
|
|
17
|
+
✅ done · 🔶 partial · ⏳ planned · 💤 deferred
|
|
18
|
+
|
|
19
|
+
## Feature tree
|
|
20
|
+
|
|
21
|
+
| ID | Feature | Status | Parent | Notes |
|
|
22
|
+
|----|---------|--------|--------|-------|
|
|
23
|
+
| F1 | _(root feature)_ | ⏳ planned | — | _(one-line scope)_ |
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: Project Constitution
|
|
3
|
+
doc: 99_PROJECT_CONSTITUTION
|
|
4
|
+
owns: PROCESS — how the key files are maintained
|
|
5
|
+
authority: authoritative-on-process
|
|
6
|
+
version: 1.0.0
|
|
7
|
+
created_at: 1970-01-01T00:00:00.000Z
|
|
8
|
+
updated_at: 1970-01-01T00:00:00.000Z
|
|
9
|
+
---
|
|
10
|
+
|
|
11
|
+
# Project Constitution — How to Organize the Project
|
|
12
|
+
|
|
13
|
+
> **This is a template.** Spur's own constitution at
|
|
14
|
+
> [docs/99_PROJECT_CONSTITUTION.md](https://github.com/gobing-ai/spur/blob/main/docs/99_PROJECT_CONSTITUTION.md)
|
|
15
|
+
> is the canonical version. Copy the full content there into this file for a real project, then
|
|
16
|
+
> localize the Lessons section (§8) and the tool-binding column (§3).
|
|
17
|
+
|
|
18
|
+
## 1. What this is & what this is not
|
|
19
|
+
|
|
20
|
+
This is the **constitution** for the project's key files: an accumulated, machine-maintained set
|
|
21
|
+
of rules and lessons for running the same file structure across different projects and
|
|
22
|
+
cooperating with multiple coding agents (Claude Code, Codex, Gemini CLI, pi, Antigravity,
|
|
23
|
+
OpenCode, OpenClaw, ...).
|
|
24
|
+
|
|
25
|
+
- One copy lives in every project at `docs/99_PROJECT_CONSTITUTION.md`.
|
|
26
|
+
- It is **byte-identical across projects** except the Lessons sections (§8) and the tool-binding
|
|
27
|
+
column (§3). When it improves in one project, propagate to the others — forks are drift.
|
|
28
|
+
- It contains **zero project-specific facts** — no project command names, package names, feature
|
|
29
|
+
states, or decisions. Project facts live in the numbered docs this file governs.
|
|
30
|
+
|
|
31
|
+
## 2. Authority model
|
|
32
|
+
|
|
33
|
+
| Axis | Question | Winner |
|
|
34
|
+
|------|----------|--------|
|
|
35
|
+
| **Content** | What is true about the project? | Lower number wins: `00_ADR` is binding on *decisions*; `01_PRD` is authoritative on *scope*; `02`–`05` are derived |
|
|
36
|
+
| **Process** | How are the key files maintained? | **This file** |
|
|
37
|
+
|
|
38
|
+
## 3. Doc map
|
|
39
|
+
|
|
40
|
+
| Doc | Owns the question | Authority |
|
|
41
|
+
|-----|-------------------|-----------|
|
|
42
|
+
| `00_ADR.md` | **WHY** — decisions + one-line reason | Authoritative (wins all) |
|
|
43
|
+
| `01_PRD.md` | **WHAT** — product vision, scope | Authoritative on scope |
|
|
44
|
+
| `02_ROADMAP.md` | **WHEN** — phases, sequencing | Derived |
|
|
45
|
+
| `03_ARCHITECTURE.md` | **HOW** — module boundaries, data flow | Derived |
|
|
46
|
+
| `04_DESIGN.md` | **SURFACE** — commands, flags, schemas | Derived |
|
|
47
|
+
| `05_FEATURES.md` | **STATUS** — feature decomposition + state | Derived |
|
|
48
|
+
| `99_PROJECT_CONSTITUTION.md` | **PROCESS** — how files are maintained | Authoritative on process |
|
|
49
|
+
|
|
50
|
+
## 4. Sync triggers
|
|
51
|
+
|
|
52
|
+
When a change touches one of these, the listed doc MUST be updated in the **same commit**:
|
|
53
|
+
|
|
54
|
+
| ID | Trigger | Doc(s) |
|
|
55
|
+
|----|---------|--------|
|
|
56
|
+
| T1 | New cross-cutting decision | `00` first, then `03` mechanism |
|
|
57
|
+
| T3 | Command/flag/config/schema/DTO added/changed | `04` + `AGENTS.md` |
|
|
58
|
+
| T4 | Feature ships or changes state | `05` row |
|
|
59
|
+
| T6 | Scope added / cut / deferred | `01` |
|
|
60
|
+
|
|
61
|
+
## 5. Lessons
|
|
62
|
+
|
|
63
|
+
| Date | Lesson |
|
|
64
|
+
|------|--------|
|
|
65
|
+
| 1970-01-01 | _(empty — add lessons as the project evolves)_ |
|