lean-spec 0.2.5 → 0.2.6-dev.20251125015611
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/dist/{chunk-7WXYOHZU.js → chunk-RTEGSMVL.js} +1253 -678
- package/dist/chunk-RTEGSMVL.js.map +1 -0
- package/dist/cli.js +7 -1
- package/dist/cli.js.map +1 -1
- package/dist/mcp-server.js +1 -1
- package/package.json +2 -3
- package/templates/detailed/AGENTS.md +113 -0
- package/templates/detailed/README.md +28 -0
- package/templates/detailed/files/DESIGN.md +43 -0
- package/templates/detailed/files/PLAN.md +59 -0
- package/templates/detailed/files/README.md +30 -0
- package/templates/detailed/files/TEST.md +71 -0
- package/templates/examples/api-refactor/README.md +81 -0
- package/templates/examples/api-refactor/package.json +16 -0
- package/templates/examples/api-refactor/src/app.js +40 -0
- package/templates/examples/api-refactor/src/services/currencyService.js +43 -0
- package/templates/examples/api-refactor/src/services/timezoneService.js +41 -0
- package/templates/examples/api-refactor/src/services/weatherService.js +42 -0
- package/templates/examples/dark-theme/README.md +66 -0
- package/templates/examples/dark-theme/package.json +16 -0
- package/templates/examples/dark-theme/src/public/app.js +277 -0
- package/templates/examples/dark-theme/src/public/index.html +225 -0
- package/templates/examples/dark-theme/src/public/style.css +625 -0
- package/templates/examples/dark-theme/src/server.js +18 -0
- package/templates/examples/dashboard-widgets/README.md +70 -0
- package/templates/examples/dashboard-widgets/index.html +12 -0
- package/templates/examples/dashboard-widgets/package.json +22 -0
- package/templates/examples/dashboard-widgets/src/App.css +20 -0
- package/templates/examples/dashboard-widgets/src/App.jsx +16 -0
- package/templates/examples/dashboard-widgets/src/components/Dashboard.css +17 -0
- package/templates/examples/dashboard-widgets/src/components/Dashboard.jsx +15 -0
- package/templates/examples/dashboard-widgets/src/components/WidgetWrapper.css +23 -0
- package/templates/examples/dashboard-widgets/src/components/WidgetWrapper.jsx +16 -0
- package/templates/examples/dashboard-widgets/src/components/widgets/ChartWidget.css +33 -0
- package/templates/examples/dashboard-widgets/src/components/widgets/ChartWidget.jsx +28 -0
- package/templates/examples/dashboard-widgets/src/components/widgets/StatsWidget.css +24 -0
- package/templates/examples/dashboard-widgets/src/components/widgets/StatsWidget.jsx +22 -0
- package/templates/examples/dashboard-widgets/src/index.css +13 -0
- package/templates/examples/dashboard-widgets/src/main.jsx +10 -0
- package/templates/examples/dashboard-widgets/src/utils/mockData.js +30 -0
- package/templates/examples/dashboard-widgets/vite.config.js +6 -0
- package/templates/standard/AGENTS.md +113 -0
- package/templates/standard/README.md +4 -2
- package/dist/chunk-7WXYOHZU.js.map +0 -1
- package/templates/_shared/agents-components/core-rules-base-additions.md +0 -4
- package/templates/_shared/agents-components/core-rules-enterprise-additions.md +0 -4
- package/templates/_shared/agents-components/core-rules-shared.md +0 -1
- package/templates/_shared/agents-components/discovery-commands-enterprise-additions.md +0 -6
- package/templates/_shared/agents-components/discovery-commands-minimal-additions.md +0 -0
- package/templates/_shared/agents-components/discovery-commands-shared.md +0 -8
- package/templates/_shared/agents-components/discovery-commands-standard-additions.md +0 -3
- package/templates/_shared/agents-components/enterprise-approval.md +0 -10
- package/templates/_shared/agents-components/enterprise-compliance.md +0 -12
- package/templates/_shared/agents-components/enterprise-when-required.md +0 -13
- package/templates/_shared/agents-components/essential-commands-enterprise-additions.md +0 -29
- package/templates/_shared/agents-components/essential-commands-minimal-additions.md +0 -1
- package/templates/_shared/agents-components/essential-commands-shared.md +0 -15
- package/templates/_shared/agents-components/essential-commands-standard-additions.md +0 -18
- package/templates/_shared/agents-components/frontmatter-enterprise.md +0 -33
- package/templates/_shared/agents-components/frontmatter-minimal.md +0 -18
- package/templates/_shared/agents-components/frontmatter-standard.md +0 -23
- package/templates/_shared/agents-components/quality-standards-enterprise-additions.md +0 -4
- package/templates/_shared/agents-components/quality-standards-minimal-additions.md +0 -3
- package/templates/_shared/agents-components/quality-standards-shared.md +0 -6
- package/templates/_shared/agents-components/status-update-triggers.md +0 -14
- package/templates/_shared/agents-components/when-to-use-enterprise.md +0 -11
- package/templates/_shared/agents-components/when-to-use-minimal.md +0 -9
- package/templates/_shared/agents-components/when-to-use-standard.md +0 -9
- package/templates/_shared/agents-components/workflow-enterprise.md +0 -11
- package/templates/_shared/agents-components/workflow-standard-detailed.md +0 -10
- package/templates/_shared/agents-components/workflow-standard.md +0 -8
- package/templates/_shared/agents-template.hbs +0 -43
- package/templates/enterprise/README.md +0 -25
- package/templates/enterprise/agents-config.json +0 -16
- package/templates/enterprise/files/AGENTS.md +0 -194
- package/templates/enterprise/spec-template.md +0 -80
- package/templates/minimal/README.md +0 -18
- package/templates/minimal/agents-config.json +0 -13
- package/templates/minimal/config.json +0 -15
- package/templates/minimal/files/AGENTS.md +0 -116
- package/templates/minimal/spec-template.md +0 -25
- package/templates/standard/agents-config.json +0 -13
- package/templates/standard/files/AGENTS.md +0 -142
- /package/templates/{enterprise → detailed}/config.json +0 -0
- /package/templates/standard/{spec-template.md → files/README.md} +0 -0
|
@@ -1,80 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
status: planned
|
|
3
|
-
created: '{date}'
|
|
4
|
-
tags: []
|
|
5
|
-
priority: medium
|
|
6
|
-
assignee:
|
|
7
|
-
reviewer:
|
|
8
|
-
related: []
|
|
9
|
-
issue:
|
|
10
|
-
epic:
|
|
11
|
-
---
|
|
12
|
-
|
|
13
|
-
# {name}
|
|
14
|
-
|
|
15
|
-
> **Status**: {status} · **Priority**: {priority} · **Created**: {date}
|
|
16
|
-
> **Assignee**: {assignee} · **Reviewer**: {reviewer}
|
|
17
|
-
|
|
18
|
-
## Overview
|
|
19
|
-
|
|
20
|
-
<!-- What business problem? Why now? Expected impact? -->
|
|
21
|
-
|
|
22
|
-
## Research
|
|
23
|
-
|
|
24
|
-
<!-- Background investigation, alternatives evaluated, key findings -->
|
|
25
|
-
|
|
26
|
-
## Design
|
|
27
|
-
|
|
28
|
-
<!-- Architecture, system interactions, data flows -->
|
|
29
|
-
|
|
30
|
-
### Dependencies
|
|
31
|
-
|
|
32
|
-
- **Teams**: <!-- Which teams need to coordinate? -->
|
|
33
|
-
- **Systems**: <!-- External systems affected -->
|
|
34
|
-
- **Data**: <!-- Databases, APIs, shared resources -->
|
|
35
|
-
|
|
36
|
-
### Security & Compliance
|
|
37
|
-
|
|
38
|
-
- [ ] Handles sensitive data (PII, credentials, etc.)
|
|
39
|
-
- [ ] Security implications reviewed
|
|
40
|
-
- [ ] Compliance requirements identified
|
|
41
|
-
|
|
42
|
-
## Plan
|
|
43
|
-
|
|
44
|
-
<!-- Break into phases if needed -->
|
|
45
|
-
|
|
46
|
-
<!-- 💡 TIP: If your plan has >6 phases or this spec approaches
|
|
47
|
-
400 lines, consider using sub-spec files:
|
|
48
|
-
- IMPLEMENTATION.md for detailed implementation
|
|
49
|
-
- See spec 012-sub-spec-files for guidance on splitting -->
|
|
50
|
-
|
|
51
|
-
- [ ] Task 1 - @owner
|
|
52
|
-
- [ ] Task 2 - @owner
|
|
53
|
-
- [ ] Task 3 - @owner
|
|
54
|
-
|
|
55
|
-
## Test
|
|
56
|
-
|
|
57
|
-
<!-- How to verify correctness and safety -->
|
|
58
|
-
|
|
59
|
-
- [ ] Unit/integration tests
|
|
60
|
-
- [ ] Load/performance testing
|
|
61
|
-
- [ ] Security testing
|
|
62
|
-
- [ ] Rollback plan
|
|
63
|
-
|
|
64
|
-
## Risks
|
|
65
|
-
|
|
66
|
-
| Risk | Impact | Mitigation |
|
|
67
|
-
|------|--------|------------|
|
|
68
|
-
| | | |
|
|
69
|
-
|
|
70
|
-
## Rollout
|
|
71
|
-
|
|
72
|
-
<!-- Deployment strategy for production systems -->
|
|
73
|
-
|
|
74
|
-
- Staging validation:
|
|
75
|
-
- Production approach:
|
|
76
|
-
- Monitoring:
|
|
77
|
-
|
|
78
|
-
## Notes
|
|
79
|
-
|
|
80
|
-
<!-- Key decisions, constraints, unresolved questions -->
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
# Minimal Template
|
|
2
|
-
|
|
3
|
-
Bare essentials. Just the spec folder structure, nothing else.
|
|
4
|
-
|
|
5
|
-
## What's Included
|
|
6
|
-
|
|
7
|
-
- Spec folder structure (`specs/YYYYMMDD/NNN-name/`)
|
|
8
|
-
- That's it
|
|
9
|
-
|
|
10
|
-
## When to Use
|
|
11
|
-
|
|
12
|
-
- You want maximum flexibility
|
|
13
|
-
- Adding LeanSpec to existing project with established practices
|
|
14
|
-
- Don't need AI agent instructions
|
|
15
|
-
|
|
16
|
-
## Next Steps
|
|
17
|
-
|
|
18
|
-
Create your first spec: `lean-spec create my-feature`
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"description": "Lightweight spec methodology for AI-powered development.",
|
|
3
|
-
"coreRules": ["core-rules-base-additions.md", "core-rules-shared.md"],
|
|
4
|
-
"whenToUse": "when-to-use-minimal.md",
|
|
5
|
-
"whenToUseEarly": true,
|
|
6
|
-
"discoveryCommands": ["discovery-commands-shared.md", "discovery-commands-minimal-additions.md"],
|
|
7
|
-
"essentialCommands": ["essential-commands-shared.md", "essential-commands-minimal-additions.md"],
|
|
8
|
-
"frontmatter": "frontmatter-minimal.md",
|
|
9
|
-
"workflow": ["workflow-standard.md", "status-update-triggers.md"],
|
|
10
|
-
"qualityStandards": ["quality-standards-minimal-additions.md", "quality-standards-shared.md"],
|
|
11
|
-
"closingNote": "**Remember**: LeanSpec is a mindset. Adapt these guidelines to what actually helps.",
|
|
12
|
-
"additionalSections": []
|
|
13
|
-
}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "Minimal",
|
|
3
|
-
"description": "Just the essentials - folder structure only",
|
|
4
|
-
"config": {
|
|
5
|
-
"template": "minimal",
|
|
6
|
-
"specsDir": "specs",
|
|
7
|
-
"structure": {
|
|
8
|
-
"pattern": "flat",
|
|
9
|
-
"prefix": "",
|
|
10
|
-
"dateFormat": "YYYYMMDD",
|
|
11
|
-
"sequenceDigits": 3,
|
|
12
|
-
"defaultFile": "README.md"
|
|
13
|
-
}
|
|
14
|
-
}
|
|
15
|
-
}
|
|
@@ -1,116 +0,0 @@
|
|
|
1
|
-
# AI Agent Instructions
|
|
2
|
-
|
|
3
|
-
## Project: {project_name}
|
|
4
|
-
|
|
5
|
-
Lightweight spec methodology for AI-powered development.
|
|
6
|
-
|
|
7
|
-
## Core Rules
|
|
8
|
-
|
|
9
|
-
1. **Read README.md first** - Understand project context
|
|
10
|
-
2. **Check specs/** - Review existing specs before starting
|
|
11
|
-
3. **Follow LeanSpec principles** - Clarity over documentation
|
|
12
|
-
4. **Keep it minimal** - If it doesn't add clarity, cut it
|
|
13
|
-
5. **Never use nested code blocks** - Markdown doesn't support code blocks within code blocks. Use indentation or describe the structure instead
|
|
14
|
-
|
|
15
|
-
## When to Use Specs
|
|
16
|
-
|
|
17
|
-
- Features that affect multiple parts of the system
|
|
18
|
-
- Breaking changes or significant refactors
|
|
19
|
-
- Design decisions that need thinking through
|
|
20
|
-
- Complex features that benefit from upfront planning
|
|
21
|
-
|
|
22
|
-
Skip specs for:
|
|
23
|
-
- Bug fixes
|
|
24
|
-
- Trivial changes
|
|
25
|
-
- Self-explanatory refactors
|
|
26
|
-
|
|
27
|
-
## Discovery Commands
|
|
28
|
-
|
|
29
|
-
Before starting work, understand project context:
|
|
30
|
-
|
|
31
|
-
- `lean-spec stats` - See work distribution
|
|
32
|
-
- `lean-spec board` - View specs by status
|
|
33
|
-
- `lean-spec search "<query>"` - Find relevant work
|
|
34
|
-
- `lean-spec list` - List all specs
|
|
35
|
-
|
|
36
|
-
These help you understand what exists and what's in progress.
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
## Essential Commands
|
|
40
|
-
|
|
41
|
-
**Discovery:**
|
|
42
|
-
- `lean-spec list` - See all specs
|
|
43
|
-
- `lean-spec search "<query>"` - Find relevant specs
|
|
44
|
-
|
|
45
|
-
**Viewing specs:**
|
|
46
|
-
- `lean-spec view <spec>` - View a spec (formatted)
|
|
47
|
-
- `lean-spec open <spec>` - Open spec in editor
|
|
48
|
-
|
|
49
|
-
**Working with specs:**
|
|
50
|
-
- `lean-spec create <name>` - Create a new spec
|
|
51
|
-
- `lean-spec update <spec> --status <status>` - Update spec status
|
|
52
|
-
|
|
53
|
-
**When in doubt:** Run `lean-spec --help` to see all available commands.
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
## Spec Frontmatter
|
|
57
|
-
|
|
58
|
-
When creating or updating specs, add YAML frontmatter at the top:
|
|
59
|
-
|
|
60
|
-
```yaml
|
|
61
|
-
---
|
|
62
|
-
status: draft|planned|in-progress|complete|blocked|cancelled
|
|
63
|
-
created: YYYY-MM-DD
|
|
64
|
-
---
|
|
65
|
-
```
|
|
66
|
-
|
|
67
|
-
**Keep it simple:**
|
|
68
|
-
- Just `status` and `created` fields
|
|
69
|
-
- Other fields are optional - only add if helpful
|
|
70
|
-
- Update `status` as work progresses
|
|
71
|
-
|
|
72
|
-
**Update status with:**
|
|
73
|
-
```bash
|
|
74
|
-
lean-spec update <spec> --status in-progress
|
|
75
|
-
```
|
|
76
|
-
|
|
77
|
-
## Workflow
|
|
78
|
-
|
|
79
|
-
1. **Check existing work** - Run `lean-spec board` or `lean-spec search`
|
|
80
|
-
2. **Create or update spec** - Add frontmatter with `status` and `created` (status: `planned`)
|
|
81
|
-
3. **Start implementation** - Mark `in-progress` BEFORE implementing what the spec describes
|
|
82
|
-
4. **Implement changes** - Keep spec in sync as you learn
|
|
83
|
-
5. **Complete implementation** - Mark `complete` AFTER implementing what the spec describes
|
|
84
|
-
6. **Archive when done** - `lean-spec archive <spec>` moves to archive
|
|
85
|
-
|
|
86
|
-
**Remember**: Status tracks implementation work, not spec document creation. Creating a spec = planning (stays `planned` until implementation starts).
|
|
87
|
-
**CRITICAL - What "Work" Means:**
|
|
88
|
-
- ❌ **NOT**: Creating/writing the spec document itself
|
|
89
|
-
- ✅ **YES**: Implementing what the spec describes (code, docs, features, etc.)
|
|
90
|
-
- **Example**: Creating a spec for "API redesign" ≠ work complete
|
|
91
|
-
- Work = Actually redesigning the API as described in the spec
|
|
92
|
-
- Status `planned` until someone starts the redesign
|
|
93
|
-
- Status `in-progress` while redesigning
|
|
94
|
-
- Status `complete` after redesign is done
|
|
95
|
-
|
|
96
|
-
**Status Update Triggers:**
|
|
97
|
-
- ✅ **Before starting implementation** → `lean-spec update <spec> --status in-progress`
|
|
98
|
-
- ✅ **After completing implementation** → `lean-spec update <spec> --status complete`
|
|
99
|
-
- ✅ **If blocked or paused** → Update status and document why in spec
|
|
100
|
-
- ❌ **NEVER mark spec complete just because you finished writing it**
|
|
101
|
-
|
|
102
|
-
## Quality Standards
|
|
103
|
-
|
|
104
|
-
- Tests cover critical paths
|
|
105
|
-
- No unnecessary complexity
|
|
106
|
-
- Documentation where needed (not everywhere)
|
|
107
|
-
- Code is clear and maintainable
|
|
108
|
-
- Specs stay in sync with implementation
|
|
109
|
-
- **Status tracking is mandatory:**
|
|
110
|
-
- Mark spec as `in-progress` BEFORE starting work
|
|
111
|
-
- Mark spec as `complete` IMMEDIATELY after finishing
|
|
112
|
-
- Never leave specs with stale status
|
|
113
|
-
|
|
114
|
-
---
|
|
115
|
-
|
|
116
|
-
**Remember**: LeanSpec is a mindset. Adapt these guidelines to what actually helps.
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
status: planned
|
|
3
|
-
created: '{date}'
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
# {name}
|
|
7
|
-
|
|
8
|
-
> **Status**: {status} · **Created**: {date}
|
|
9
|
-
|
|
10
|
-
## Goal
|
|
11
|
-
|
|
12
|
-
<!-- What problem does this solve? Why now? -->
|
|
13
|
-
|
|
14
|
-
## Key Points
|
|
15
|
-
|
|
16
|
-
-
|
|
17
|
-
-
|
|
18
|
-
|
|
19
|
-
## Non-Goals
|
|
20
|
-
|
|
21
|
-
-
|
|
22
|
-
|
|
23
|
-
## Notes
|
|
24
|
-
|
|
25
|
-
<!-- Decisions, constraints, open questions -->
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"description": "Lightweight spec methodology for AI-powered development.",
|
|
3
|
-
"coreRules": ["core-rules-base-additions.md", "core-rules-shared.md"],
|
|
4
|
-
"whenToUse": "when-to-use-standard.md",
|
|
5
|
-
"whenToUseEarly": true,
|
|
6
|
-
"discoveryCommands": ["discovery-commands-shared.md", "discovery-commands-standard-additions.md"],
|
|
7
|
-
"essentialCommands": ["essential-commands-shared.md", "essential-commands-standard-additions.md"],
|
|
8
|
-
"frontmatter": "frontmatter-standard.md",
|
|
9
|
-
"workflow": ["workflow-standard-detailed.md", "status-update-triggers.md"],
|
|
10
|
-
"qualityStandards": ["quality-standards-minimal-additions.md", "quality-standards-shared.md"],
|
|
11
|
-
"closingNote": "**Remember**: LeanSpec is a mindset. Adapt these guidelines to what actually helps.",
|
|
12
|
-
"additionalSections": []
|
|
13
|
-
}
|
|
@@ -1,142 +0,0 @@
|
|
|
1
|
-
# AI Agent Instructions
|
|
2
|
-
|
|
3
|
-
## Project: {project_name}
|
|
4
|
-
|
|
5
|
-
Lightweight spec methodology for AI-powered development.
|
|
6
|
-
|
|
7
|
-
## Core Rules
|
|
8
|
-
|
|
9
|
-
1. **Read README.md first** - Understand project context
|
|
10
|
-
2. **Check specs/** - Review existing specs before starting
|
|
11
|
-
3. **Follow LeanSpec principles** - Clarity over documentation
|
|
12
|
-
4. **Keep it minimal** - If it doesn't add clarity, cut it
|
|
13
|
-
5. **Never use nested code blocks** - Markdown doesn't support code blocks within code blocks. Use indentation or describe the structure instead
|
|
14
|
-
|
|
15
|
-
## When to Use Specs
|
|
16
|
-
|
|
17
|
-
- Features that affect multiple parts of the system
|
|
18
|
-
- Breaking changes or significant refactors
|
|
19
|
-
- Design decisions that need team alignment
|
|
20
|
-
- Complex features that benefit from upfront thinking
|
|
21
|
-
|
|
22
|
-
Skip specs for:
|
|
23
|
-
- Bug fixes
|
|
24
|
-
- Trivial changes
|
|
25
|
-
- Self-explanatory refactors
|
|
26
|
-
|
|
27
|
-
## Discovery Commands
|
|
28
|
-
|
|
29
|
-
Before starting work, understand project context:
|
|
30
|
-
|
|
31
|
-
- `lean-spec stats` - See work distribution
|
|
32
|
-
- `lean-spec board` - View specs by status
|
|
33
|
-
- `lean-spec search "<query>"` - Find relevant work
|
|
34
|
-
- `lean-spec list` - List all specs
|
|
35
|
-
|
|
36
|
-
These help you understand what exists and what's in progress.
|
|
37
|
-
**Additional commands:**
|
|
38
|
-
- `lean-spec list --tag=<tag>` - Find specs by tag (e.g., `--tag=api`)
|
|
39
|
-
- `lean-spec deps <spec>` - Check dependencies before starting work
|
|
40
|
-
|
|
41
|
-
## Essential Commands
|
|
42
|
-
|
|
43
|
-
**Discovery:**
|
|
44
|
-
- `lean-spec list` - See all specs
|
|
45
|
-
- `lean-spec search "<query>"` - Find relevant specs
|
|
46
|
-
|
|
47
|
-
**Viewing specs:**
|
|
48
|
-
- `lean-spec view <spec>` - View a spec (formatted)
|
|
49
|
-
- `lean-spec open <spec>` - Open spec in editor
|
|
50
|
-
|
|
51
|
-
**Working with specs:**
|
|
52
|
-
- `lean-spec create <name>` - Create a new spec
|
|
53
|
-
- `lean-spec update <spec> --status <status>` - Update spec status
|
|
54
|
-
|
|
55
|
-
**When in doubt:** Run `lean-spec --help` to see all available commands.
|
|
56
|
-
**Viewing specs (additional):**
|
|
57
|
-
- `lean-spec view <spec> --raw` - Get raw markdown
|
|
58
|
-
- `lean-spec files <spec>` - List all files in a spec
|
|
59
|
-
|
|
60
|
-
**Project Overview:**
|
|
61
|
-
- `lean-spec board` - Kanban view with project health summary
|
|
62
|
-
- `lean-spec stats` - Quick project metrics
|
|
63
|
-
|
|
64
|
-
**Working with specs (additional):**
|
|
65
|
-
- `lean-spec update <spec> --priority <priority>` - Update spec priority
|
|
66
|
-
- `lean-spec update <spec> --tags <tag1,tag2>` - Update spec tags
|
|
67
|
-
- `lean-spec deps <spec>` - Show dependencies and relationships
|
|
68
|
-
|
|
69
|
-
**Token Management:**
|
|
70
|
-
- `lean-spec tokens <spec>` - Count tokens in a spec
|
|
71
|
-
- `lean-spec tokens` - Show token counts for all specs
|
|
72
|
-
|
|
73
|
-
**When in doubt (extended):** Run `lean-spec <command> --help` to discover available commands.
|
|
74
|
-
|
|
75
|
-
## Spec Frontmatter
|
|
76
|
-
|
|
77
|
-
When creating or updating specs, include YAML frontmatter at the top:
|
|
78
|
-
|
|
79
|
-
```yaml
|
|
80
|
-
---
|
|
81
|
-
status: draft|planned|in-progress|complete|blocked|cancelled
|
|
82
|
-
created: YYYY-MM-DD
|
|
83
|
-
tags: [tag1, tag2] # helps with discovery
|
|
84
|
-
priority: low|medium|high # helps with planning
|
|
85
|
-
assignee: username # for team coordination
|
|
86
|
-
---
|
|
87
|
-
```
|
|
88
|
-
|
|
89
|
-
**Core fields:**
|
|
90
|
-
- `status` and `created` are required
|
|
91
|
-
- `tags` help with discovery and organization
|
|
92
|
-
- `priority` helps teams plan work
|
|
93
|
-
- `assignee` shows who's working on what
|
|
94
|
-
|
|
95
|
-
**Update status with:**
|
|
96
|
-
```bash
|
|
97
|
-
lean-spec update <spec> --status in-progress --assignee yourname
|
|
98
|
-
# or edit frontmatter directly
|
|
99
|
-
```
|
|
100
|
-
|
|
101
|
-
## Workflow
|
|
102
|
-
|
|
103
|
-
1. **Discover context** - Run `lean-spec stats` or `lean-spec board` to see current state
|
|
104
|
-
2. **Search existing specs** - Use `lean-spec search` or `lean-spec list` to find relevant work
|
|
105
|
-
3. **Check dependencies** - Run `lean-spec deps <spec>` if working on existing spec
|
|
106
|
-
4. **Create or update spec** - Add frontmatter with required fields (status: `planned`)
|
|
107
|
-
5. **Start implementation** - Mark `in-progress` BEFORE implementing what the spec describes
|
|
108
|
-
6. **Implement changes** - Keep spec in sync as you learn
|
|
109
|
-
7. **Complete implementation** - Mark `complete` AFTER implementing what the spec describes
|
|
110
|
-
8. **Archive when done** - `lean-spec archive <spec>` moves to archive
|
|
111
|
-
|
|
112
|
-
**Remember**: Status tracks implementation work, not spec document creation. Creating a spec = planning (stays `planned` until implementation starts).
|
|
113
|
-
**CRITICAL - What "Work" Means:**
|
|
114
|
-
- ❌ **NOT**: Creating/writing the spec document itself
|
|
115
|
-
- ✅ **YES**: Implementing what the spec describes (code, docs, features, etc.)
|
|
116
|
-
- **Example**: Creating a spec for "API redesign" ≠ work complete
|
|
117
|
-
- Work = Actually redesigning the API as described in the spec
|
|
118
|
-
- Status `planned` until someone starts the redesign
|
|
119
|
-
- Status `in-progress` while redesigning
|
|
120
|
-
- Status `complete` after redesign is done
|
|
121
|
-
|
|
122
|
-
**Status Update Triggers:**
|
|
123
|
-
- ✅ **Before starting implementation** → `lean-spec update <spec> --status in-progress`
|
|
124
|
-
- ✅ **After completing implementation** → `lean-spec update <spec> --status complete`
|
|
125
|
-
- ✅ **If blocked or paused** → Update status and document why in spec
|
|
126
|
-
- ❌ **NEVER mark spec complete just because you finished writing it**
|
|
127
|
-
|
|
128
|
-
## Quality Standards
|
|
129
|
-
|
|
130
|
-
- Tests cover critical paths
|
|
131
|
-
- No unnecessary complexity
|
|
132
|
-
- Documentation where needed (not everywhere)
|
|
133
|
-
- Code is clear and maintainable
|
|
134
|
-
- Specs stay in sync with implementation
|
|
135
|
-
- **Status tracking is mandatory:**
|
|
136
|
-
- Mark spec as `in-progress` BEFORE starting work
|
|
137
|
-
- Mark spec as `complete` IMMEDIATELY after finishing
|
|
138
|
-
- Never leave specs with stale status
|
|
139
|
-
|
|
140
|
-
---
|
|
141
|
-
|
|
142
|
-
**Remember**: LeanSpec is a mindset. Adapt these guidelines to what actually helps.
|
|
File without changes
|
|
File without changes
|