gspec 1.0.0 → 1.0.3
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/LICENSE +21 -0
- package/README.md +106 -48
- package/bin/gspec.js +23 -16
- package/commands/gspec.dor.md +15 -1
- package/commands/gspec.record.md +4 -1
- package/dist/antigravity/gspec-dor/SKILL.md +15 -1
- package/dist/antigravity/gspec-record/SKILL.md +4 -1
- package/dist/claude/gspec-dor/SKILL.md +15 -1
- package/dist/claude/gspec-record/SKILL.md +4 -1
- package/dist/cursor/gspec-dor.mdc +15 -1
- package/dist/cursor/gspec-record.mdc +4 -1
- package/package.json +6 -3
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2025 Baller Software
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
CHANGED
|
@@ -1,76 +1,100 @@
|
|
|
1
|
-
# gspec
|
|
1
|
+
# gspec
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
**Structured product specifications for AI-assisted development.**
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
AI coding tools are powerful, but they build better software when they understand *what* you're building and *why*. gspec gives your AI tools that context — a set of living specification documents that define your product, guide implementation, and stay in sync as your project evolves.
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
Without structured context, AI tools guess. They make assumptions about your audience, your tech stack, your design language, and your quality standards. gspec eliminates that guesswork by creating a shared specification layer that any AI coding tool can read and follow.
|
|
8
8
|
|
|
9
|
-
|
|
9
|
+
## The Problem
|
|
10
10
|
|
|
11
|
-
|
|
12
|
-
npx gspec
|
|
13
|
-
```
|
|
11
|
+
Two things go wrong when building with AI:
|
|
14
12
|
|
|
15
|
-
|
|
13
|
+
1. **AI tools lack product context.** They don't know your target audience, your design system, your architectural decisions, or your engineering standards. Every prompt starts from zero.
|
|
14
|
+
2. **Specs drift from reality.** Even when you write great specs upfront, they fall out of sync as the project evolves — leading to inconsistency, rework, and compounding confusion.
|
|
16
15
|
|
|
17
|
-
|
|
16
|
+
gspec solves both problems. It provides a structured specification workflow that gives AI tools rich context, and keeps that context accurate as your codebase changes.
|
|
18
17
|
|
|
19
|
-
|
|
20
|
-
npx gspec --target cursor
|
|
21
|
-
```
|
|
18
|
+
## How It Works
|
|
22
19
|
|
|
23
|
-
|
|
20
|
+
gspec installs as a set of slash commands (skills) in your AI coding tool. Each command plays a specific role — business strategist, product manager, architect, designer, engineer — and produces a structured Markdown document in your project's `gspec/` directory.
|
|
24
21
|
|
|
25
|
-
|
|
22
|
+
These documents become the shared context for all subsequent AI interactions. When you implement features, your AI reads the specs. When the code changes, the specs update to match.
|
|
26
23
|
|
|
27
|
-
|
|
28
|
-
|
|
24
|
+
### The Workflow
|
|
25
|
+
|
|
26
|
+
```
|
|
27
|
+
Define → Specify → Build → Iterate
|
|
29
28
|
```
|
|
30
29
|
|
|
31
|
-
|
|
30
|
+
**1. Define the Fundamentals** — Establish the foundation that drives every decision.
|
|
31
|
+
|
|
32
|
+
| Command | Role | What it produces |
|
|
33
|
+
|---|---|---|
|
|
34
|
+
| `gspec.profile` | Business Strategist | Product identity, audience, value proposition, positioning |
|
|
35
|
+
| `gspec.style` | UI/UX Designer | Visual design language, design tokens, component patterns |
|
|
36
|
+
| `gspec.stack` | Software Architect | Technology stack, frameworks, infrastructure, architecture |
|
|
37
|
+
| `gspec.practices` | Engineering Lead | Development standards, code quality, testing, workflows |
|
|
32
38
|
|
|
33
|
-
|
|
39
|
+
**2. Specify What to Build** — Define features and requirements.
|
|
34
40
|
|
|
35
|
-
| Command | Role |
|
|
36
|
-
|
|
37
|
-
| `gspec.
|
|
38
|
-
| `gspec.
|
|
39
|
-
| `gspec.epic` | Product Manager | `gspec/epics/<name>.md` + `gspec/features/*.md` | Breaks down a large epic into multiple focused feature PRDs with dependency mapping and phasing |
|
|
40
|
-
| `gspec.style` | UI/UX Designer | `gspec/style.md` | Visual style guide, design tokens, and component patterns |
|
|
41
|
-
| `gspec.stack` | Software Architect | `gspec/stack.md` | Technology stack, frameworks, infrastructure, and tooling |
|
|
42
|
-
| `gspec.practices` | Engineering Lead | `gspec/practices.md` | Development practices, code quality standards, and workflows |
|
|
43
|
-
| `gspec.implement` | Senior Engineer / Tech Lead | Code files | Reads gspec docs, identifies gaps, plans and builds the software |
|
|
44
|
-
| `gspec.dor` | Engineer + Doc Lead | Code files + `gspec/*.md` | Makes code changes and updates gspec specs to keep documentation in sync |
|
|
45
|
-
| `gspec.record` | Doc Lead | `gspec/*.md` | Updates gspec specs to reflect changes, decisions, or context — no code changes |
|
|
41
|
+
| Command | Role | What it produces |
|
|
42
|
+
|---|---|---|
|
|
43
|
+
| `gspec.feature` | Product Manager | PRD for a single feature with prioritized capabilities |
|
|
44
|
+
| `gspec.epic` | Product Manager | Breaks a large epic into multiple feature PRDs with dependency mapping |
|
|
46
45
|
|
|
47
|
-
|
|
46
|
+
**3. Build** — Implement with full context.
|
|
47
|
+
|
|
48
|
+
| Command | Role | What it does |
|
|
49
|
+
|---|---|---|
|
|
50
|
+
| `gspec.implement` | Senior Engineer | Reads all specs, identifies gaps, researches competitors, plans and builds |
|
|
51
|
+
|
|
52
|
+
**4. Iterate** — Keep specs and code in sync as the project evolves.
|
|
53
|
+
|
|
54
|
+
| Command | Role | What it does |
|
|
55
|
+
|---|---|---|
|
|
56
|
+
| `gspec.dor` | Engineer + Doc Lead | Makes code changes and updates specs to match |
|
|
57
|
+
| `gspec.record` | Doc Lead | Updates specs to reflect decisions or changes — no code modifications |
|
|
58
|
+
|
|
59
|
+
Each command is self-contained and will ask clarifying questions when essential information is missing.
|
|
60
|
+
|
|
61
|
+
## Installation
|
|
62
|
+
|
|
63
|
+
Run from your project root:
|
|
64
|
+
|
|
65
|
+
```bash
|
|
66
|
+
npx gspec
|
|
67
|
+
```
|
|
48
68
|
|
|
49
|
-
|
|
69
|
+
The CLI will ask which platform you're installing for:
|
|
50
70
|
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
6. **`gspec.practices`** — Define the development standards and engineering practices
|
|
57
|
-
7. **`gspec.implement`** — Implement the software using all generated gspec documents
|
|
58
|
-
8. **`gspec.dor`** — Iterate on the codebase and keep gspec specs up to date with changes
|
|
59
|
-
9. **`gspec.record`** — Record decisions, changes, or context to gspec specs without touching code
|
|
71
|
+
| Platform | Install path |
|
|
72
|
+
|---|---|
|
|
73
|
+
| Claude Code | `.claude/skills/` |
|
|
74
|
+
| Cursor | `.cursor/commands/` |
|
|
75
|
+
| Antigravity | `.agent/skills/` |
|
|
60
76
|
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
77
|
+
You can skip the prompt by passing a target directly:
|
|
78
|
+
|
|
79
|
+
```bash
|
|
80
|
+
npx gspec --target claude
|
|
81
|
+
npx gspec --target cursor
|
|
82
|
+
npx gspec --target antigravity
|
|
83
|
+
```
|
|
84
|
+
|
|
85
|
+
That's it. The commands are immediately available in your AI tool.
|
|
64
86
|
|
|
65
87
|
## Output Structure
|
|
66
88
|
|
|
89
|
+
All specifications live in a `gspec/` directory at your project root:
|
|
90
|
+
|
|
67
91
|
```
|
|
68
92
|
project-root/
|
|
69
93
|
└── gspec/
|
|
70
|
-
├── profile.md
|
|
71
|
-
├── style.md
|
|
72
|
-
├── stack.md
|
|
73
|
-
├── practices.md
|
|
94
|
+
├── profile.md # Product identity and positioning
|
|
95
|
+
├── style.md # Visual design language
|
|
96
|
+
├── stack.md # Technology stack and architecture
|
|
97
|
+
├── practices.md # Development standards
|
|
74
98
|
├── epics/
|
|
75
99
|
│ └── onboarding-flow.md
|
|
76
100
|
└── features/
|
|
@@ -78,3 +102,37 @@ project-root/
|
|
|
78
102
|
├── dashboard-analytics.md
|
|
79
103
|
└── ...
|
|
80
104
|
```
|
|
105
|
+
|
|
106
|
+
These are standard Markdown files. They live in your repo, are version-controlled with your code, and are readable by both humans and AI tools.
|
|
107
|
+
|
|
108
|
+
## Key Design Decisions
|
|
109
|
+
|
|
110
|
+
**Spec-first development.** Every implementation decision traces back to a specification. AI tools don't guess — they follow documented decisions about your product, stack, design, and standards.
|
|
111
|
+
|
|
112
|
+
**Living documents.** Specifications aren't write-once artifacts. The `dor` and `record` commands keep them in sync as your project evolves, so they remain a reliable source of truth.
|
|
113
|
+
|
|
114
|
+
**Role-based commands.** Each command adopts a specific professional perspective — product manager, architect, designer, engineer. This ensures specifications are comprehensive and consider multiple viewpoints.
|
|
115
|
+
|
|
116
|
+
**Incremental implementation.** Feature PRDs use checkboxes to track which capabilities have been built. The `implement` command reads these to know what's done and what's remaining, so it can be run multiple times as your project grows.
|
|
117
|
+
|
|
118
|
+
**Competitive research.** The `implement` command can optionally research competitors named in your product profile, identifying table-stakes features you might be missing and opportunities for differentiation.
|
|
119
|
+
|
|
120
|
+
**Platform-agnostic.** A single set of source commands builds for Claude Code, Cursor, and Antigravity. The build system handles platform-specific formatting so the commands stay consistent across tools.
|
|
121
|
+
|
|
122
|
+
## Supported Platforms
|
|
123
|
+
|
|
124
|
+
| Platform | Version | Status |
|
|
125
|
+
|---|---|---|
|
|
126
|
+
| [Claude Code](https://docs.anthropic.com/en/docs/claude-code) | Skills format | Supported |
|
|
127
|
+
| [Cursor](https://www.cursor.com/) | Commands format | Supported |
|
|
128
|
+
| [Antigravity](https://www.antigravity.dev/) | Skills format | Supported |
|
|
129
|
+
|
|
130
|
+
## Project Status
|
|
131
|
+
|
|
132
|
+
gspec is early-stage and actively evolving. The core workflow is stable, but commands and output formats may change as AI tool capabilities expand and user feedback comes in.
|
|
133
|
+
|
|
134
|
+
If you run into issues or have ideas, please [open an issue](https://github.com/gballer77/gspec/issues).
|
|
135
|
+
|
|
136
|
+
## License
|
|
137
|
+
|
|
138
|
+
[MIT](LICENSE)
|
package/bin/gspec.js
CHANGED
|
@@ -9,19 +9,21 @@ import chalk from 'chalk';
|
|
|
9
9
|
|
|
10
10
|
const __dirname = dirname(fileURLToPath(import.meta.url));
|
|
11
11
|
const DIST_DIR = join(__dirname, '..', 'dist');
|
|
12
|
+
const pkg = JSON.parse(await readFile(join(__dirname, '..', 'package.json'), 'utf-8'));
|
|
12
13
|
|
|
13
14
|
const BANNER = `
|
|
14
|
-
${chalk.cyan('
|
|
15
|
-
${chalk.cyan('║')}
|
|
16
|
-
${chalk.cyan('║')} ${chalk.bold.white(' ██████ ███████ ██████ ███████ ██████')}
|
|
17
|
-
${chalk.cyan('║')} ${chalk.bold.white('██ ██ ██ ██ ██ ██ ')}
|
|
18
|
-
${chalk.cyan('║')} ${chalk.bold.white('██ ███ ███████ ██████ █████ ██ ')}
|
|
19
|
-
${chalk.cyan('║')} ${chalk.bold.white('██ ██ ██ ██ ██ ██ ')}
|
|
20
|
-
${chalk.cyan('║')} ${chalk.bold.white(' ██████ ███████ ██ ███████ ██████')}
|
|
21
|
-
${chalk.cyan('║')}
|
|
22
|
-
${chalk.cyan('║')}
|
|
23
|
-
${chalk.cyan('║')}
|
|
24
|
-
${chalk.cyan('
|
|
15
|
+
${chalk.cyan('╔══════════════════════════════════════════════╗')}
|
|
16
|
+
${chalk.cyan('║')} ${chalk.cyan('║')}
|
|
17
|
+
${chalk.cyan('║')} ${chalk.bold.white(' ██████ ███████ ██████ ███████ ██████')} ${chalk.cyan('║')}
|
|
18
|
+
${chalk.cyan('║')} ${chalk.bold.white('██ ██ ██ ██ ██ ██ ')} ${chalk.cyan('║')}
|
|
19
|
+
${chalk.cyan('║')} ${chalk.bold.white('██ ███ ███████ ██████ █████ ██ ')} ${chalk.cyan('║')}
|
|
20
|
+
${chalk.cyan('║')} ${chalk.bold.white('██ ██ ██ ██ ██ ██ ')} ${chalk.cyan('║')}
|
|
21
|
+
${chalk.cyan('║')} ${chalk.bold.white(' ██████ ███████ ██ ███████ ██████')} ${chalk.cyan('║')}
|
|
22
|
+
${chalk.cyan('║')} ${chalk.cyan('║')}
|
|
23
|
+
${chalk.cyan('║')} ${chalk.dim('AI-powered project specification tools')} ${chalk.cyan('║')}
|
|
24
|
+
${chalk.cyan('║')} ${chalk.cyan('║')}
|
|
25
|
+
${chalk.cyan('╚══════════════════════════════════════════════╝')}
|
|
26
|
+
${chalk.white('═════════════════════════════baller.software═══')}
|
|
25
27
|
`;
|
|
26
28
|
|
|
27
29
|
const TARGETS = {
|
|
@@ -96,8 +98,9 @@ async function findExistingFiles(target, cwd) {
|
|
|
96
98
|
|
|
97
99
|
try {
|
|
98
100
|
await stat(destBase);
|
|
99
|
-
} catch {
|
|
100
|
-
return existing;
|
|
101
|
+
} catch (e) {
|
|
102
|
+
if (e.code === 'ENOENT') return existing;
|
|
103
|
+
throw e;
|
|
101
104
|
}
|
|
102
105
|
|
|
103
106
|
if (target.layout === 'flat') {
|
|
@@ -106,7 +109,9 @@ async function findExistingFiles(target, cwd) {
|
|
|
106
109
|
try {
|
|
107
110
|
await stat(join(destBase, file));
|
|
108
111
|
existing.push(file);
|
|
109
|
-
} catch {
|
|
112
|
+
} catch (e) {
|
|
113
|
+
if (e.code !== 'ENOENT') throw e;
|
|
114
|
+
}
|
|
110
115
|
}
|
|
111
116
|
} else {
|
|
112
117
|
const srcEntries = await readdir(target.sourceDir);
|
|
@@ -116,7 +121,9 @@ async function findExistingFiles(target, cwd) {
|
|
|
116
121
|
try {
|
|
117
122
|
await stat(join(destBase, entry, 'SKILL.md'));
|
|
118
123
|
existing.push(`${entry}/SKILL.md`);
|
|
119
|
-
} catch {
|
|
124
|
+
} catch (e) {
|
|
125
|
+
if (e.code !== 'ENOENT') throw e;
|
|
126
|
+
}
|
|
120
127
|
}
|
|
121
128
|
}
|
|
122
129
|
|
|
@@ -207,7 +214,7 @@ async function install(targetName, cwd) {
|
|
|
207
214
|
program
|
|
208
215
|
.name('gspec')
|
|
209
216
|
.description('Install gspec specification commands')
|
|
210
|
-
.version(
|
|
217
|
+
.version(pkg.version)
|
|
211
218
|
.option('-t, --target <target>', 'target platform (claude, cursor, antigravity)')
|
|
212
219
|
.action(async (opts) => {
|
|
213
220
|
console.log(BANNER);
|
package/commands/gspec.dor.md
CHANGED
|
@@ -58,6 +58,17 @@ Execute the code changes:
|
|
|
58
58
|
5. **Surface new issues as they arise** — If implementation reveals new ambiguities, pause and consult the user rather than making silent assumptions
|
|
59
59
|
6. **Track spec implications as you work** — As you implement, mentally note which gspec documents will need updating based on what you are changing
|
|
60
60
|
|
|
61
|
+
### Phase 3.5: Validate — Ensure Tests Pass
|
|
62
|
+
|
|
63
|
+
Before updating any specs, verify the code changes are sound:
|
|
64
|
+
|
|
65
|
+
1. **Check for existing tests** — Look for a test suite, test runner configuration, or test scripts in `package.json`, `Makefile`, or equivalent
|
|
66
|
+
2. **If tests exist, run them** — Execute the project's test suite and confirm all tests pass
|
|
67
|
+
3. **If tests fail** — Fix the failing tests before proceeding. Do not move to spec updates with a broken test suite
|
|
68
|
+
4. **If no tests exist** — Note this and proceed. Do not create a test suite unless the user requests one or `gspec/practices.md` requires it
|
|
69
|
+
|
|
70
|
+
This gate ensures specs are only updated to reflect working, validated code — never broken implementations.
|
|
71
|
+
|
|
61
72
|
### Phase 4: Assess — Determine Spec Impact
|
|
62
73
|
|
|
63
74
|
After code changes are complete, systematically evaluate which gspec documents need updating. Apply this decision matrix:
|
|
@@ -70,7 +81,8 @@ After code changes are complete, systematically evaluate which gspec documents n
|
|
|
70
81
|
| New technology or dependency added | `gspec/stack.md` | Add to appropriate section with rationale |
|
|
71
82
|
| Technology or dependency removed | `gspec/stack.md` | Remove and note why |
|
|
72
83
|
| Technology version changed | `gspec/stack.md` | Update version |
|
|
73
|
-
| Visual design change (colors, typography, spacing,
|
|
84
|
+
| Visual design change — generic (colors, typography, spacing, base component patterns) | `gspec/style.md` | Update affected tokens or base component patterns. Only include changes that are reusable and not tied to a specific feature or domain |
|
|
85
|
+
| Visual design change — feature-specific (a component unique to a feature, domain-specific visual treatment) | `gspec/features/<relevant>.md` | Document the visual details in the feature PRD's capabilities or a dedicated "Visual Design" subsection |
|
|
74
86
|
| Development practice change (testing, code org, conventions) | `gspec/practices.md` | Update affected practice |
|
|
75
87
|
| Product scope or direction change | `gspec/profile.md` | Update affected sections (Product Description, Use Cases, Roadmap, etc.) |
|
|
76
88
|
| Feature dependency change | `gspec/epics/<relevant>.md` | Update dependency map and phasing |
|
|
@@ -150,6 +162,8 @@ After writing spec updates:
|
|
|
150
162
|
|
|
151
163
|
**Traceability without clutter.** A brief note about why something changed is valuable for future readers. A changelog at the bottom of every file is not. Use judgment. For small, obvious changes, no annotation may be needed. For significant scope changes, a parenthetical note aids understanding.
|
|
152
164
|
|
|
165
|
+
**Keep `style.md` generic and reusable.** The style guide defines the design system — colors, typography, spacing, base component patterns, and tokens that could apply to any product. Do not add feature-specific or domain-specific content to `style.md` (e.g., "recipe card layout", "playlist item styling"). Feature-specific visual details belong in the relevant feature PRD. If you are unsure whether a visual change is generic or feature-specific, ask the user.
|
|
166
|
+
|
|
153
167
|
**When to create vs. update.** If a change adds a small capability that fits naturally within an existing feature PRD, update that PRD. If a change introduces a wholly new product area that does not belong in any existing PRD, create a new feature PRD. When in doubt, ask the user.
|
|
154
168
|
|
|
155
169
|
**Implementation checkboxes.** Feature PRDs use markdown checkboxes (`- [ ]` / `- [x]`) on capabilities to track implementation status for `gspec-implement`. When DOR adds new capabilities, use unchecked checkboxes (`- [ ]`). When modifying a capability that was already checked (`- [x]`) and the code change reflects the modification, keep it checked. When creating a new feature PRD, use unchecked checkboxes for all capabilities. Do not check off capabilities that DOR did not implement in the current session.
|
package/commands/gspec.record.md
CHANGED
|
@@ -65,7 +65,8 @@ Systematically evaluate which gspec documents need updating. Apply this decision
|
|
|
65
65
|
| New technology or dependency added | `gspec/stack.md` | Add to appropriate section with rationale |
|
|
66
66
|
| Technology or dependency removed | `gspec/stack.md` | Remove and note why |
|
|
67
67
|
| Technology version changed | `gspec/stack.md` | Update version |
|
|
68
|
-
| Visual design change (colors, typography, spacing,
|
|
68
|
+
| Visual design change — generic (colors, typography, spacing, base component patterns) | `gspec/style.md` | Update affected tokens or base component patterns. Only include changes that are reusable and not tied to a specific feature or domain |
|
|
69
|
+
| Visual design change — feature-specific (a component unique to a feature, domain-specific visual treatment) | `gspec/features/<relevant>.md` | Document the visual details in the feature PRD's capabilities or a dedicated "Visual Design" subsection |
|
|
69
70
|
| Development practice change (testing, code org, conventions) | `gspec/practices.md` | Update affected practice |
|
|
70
71
|
| Product scope or direction change | `gspec/profile.md` | Update affected sections (Product Description, Use Cases, Roadmap, etc.) |
|
|
71
72
|
| Feature dependency change | `gspec/epics/<relevant>.md` | Update dependency map and phasing |
|
|
@@ -143,6 +144,8 @@ After writing spec updates:
|
|
|
143
144
|
|
|
144
145
|
**Traceability without clutter.** A brief note about why something changed is valuable for future readers. A changelog at the bottom of every file is not. Use judgment.
|
|
145
146
|
|
|
147
|
+
**Keep `style.md` generic and reusable.** The style guide defines the design system — colors, typography, spacing, base component patterns, and tokens that could apply to any product. Do not add feature-specific or domain-specific content to `style.md` (e.g., "recipe card layout", "playlist item styling"). Feature-specific visual details belong in the relevant feature PRD. If you are unsure whether a visual change is generic or feature-specific, ask the user.
|
|
148
|
+
|
|
146
149
|
**When to create vs. update.** If a change adds a small capability that fits naturally within an existing feature PRD, update that PRD. If a change introduces a wholly new product area that does not belong in any existing PRD, create a new feature PRD. When in doubt, ask the user.
|
|
147
150
|
|
|
148
151
|
**No code changes.** This command never creates, modifies, or deletes code files. If the user needs code changes alongside spec updates, suggest using `gspec-dor` instead.
|
|
@@ -63,6 +63,17 @@ Execute the code changes:
|
|
|
63
63
|
5. **Surface new issues as they arise** — If implementation reveals new ambiguities, pause and consult the user rather than making silent assumptions
|
|
64
64
|
6. **Track spec implications as you work** — As you implement, mentally note which gspec documents will need updating based on what you are changing
|
|
65
65
|
|
|
66
|
+
### Phase 3.5: Validate — Ensure Tests Pass
|
|
67
|
+
|
|
68
|
+
Before updating any specs, verify the code changes are sound:
|
|
69
|
+
|
|
70
|
+
1. **Check for existing tests** — Look for a test suite, test runner configuration, or test scripts in `package.json`, `Makefile`, or equivalent
|
|
71
|
+
2. **If tests exist, run them** — Execute the project's test suite and confirm all tests pass
|
|
72
|
+
3. **If tests fail** — Fix the failing tests before proceeding. Do not move to spec updates with a broken test suite
|
|
73
|
+
4. **If no tests exist** — Note this and proceed. Do not create a test suite unless the user requests one or `gspec/practices.md` requires it
|
|
74
|
+
|
|
75
|
+
This gate ensures specs are only updated to reflect working, validated code — never broken implementations.
|
|
76
|
+
|
|
66
77
|
### Phase 4: Assess — Determine Spec Impact
|
|
67
78
|
|
|
68
79
|
After code changes are complete, systematically evaluate which gspec documents need updating. Apply this decision matrix:
|
|
@@ -75,7 +86,8 @@ After code changes are complete, systematically evaluate which gspec documents n
|
|
|
75
86
|
| New technology or dependency added | `gspec/stack.md` | Add to appropriate section with rationale |
|
|
76
87
|
| Technology or dependency removed | `gspec/stack.md` | Remove and note why |
|
|
77
88
|
| Technology version changed | `gspec/stack.md` | Update version |
|
|
78
|
-
| Visual design change (colors, typography, spacing,
|
|
89
|
+
| Visual design change — generic (colors, typography, spacing, base component patterns) | `gspec/style.md` | Update affected tokens or base component patterns. Only include changes that are reusable and not tied to a specific feature or domain |
|
|
90
|
+
| Visual design change — feature-specific (a component unique to a feature, domain-specific visual treatment) | `gspec/features/<relevant>.md` | Document the visual details in the feature PRD's capabilities or a dedicated "Visual Design" subsection |
|
|
79
91
|
| Development practice change (testing, code org, conventions) | `gspec/practices.md` | Update affected practice |
|
|
80
92
|
| Product scope or direction change | `gspec/profile.md` | Update affected sections (Product Description, Use Cases, Roadmap, etc.) |
|
|
81
93
|
| Feature dependency change | `gspec/epics/<relevant>.md` | Update dependency map and phasing |
|
|
@@ -155,6 +167,8 @@ After writing spec updates:
|
|
|
155
167
|
|
|
156
168
|
**Traceability without clutter.** A brief note about why something changed is valuable for future readers. A changelog at the bottom of every file is not. Use judgment. For small, obvious changes, no annotation may be needed. For significant scope changes, a parenthetical note aids understanding.
|
|
157
169
|
|
|
170
|
+
**Keep `style.md` generic and reusable.** The style guide defines the design system — colors, typography, spacing, base component patterns, and tokens that could apply to any product. Do not add feature-specific or domain-specific content to `style.md` (e.g., "recipe card layout", "playlist item styling"). Feature-specific visual details belong in the relevant feature PRD. If you are unsure whether a visual change is generic or feature-specific, ask the user.
|
|
171
|
+
|
|
158
172
|
**When to create vs. update.** If a change adds a small capability that fits naturally within an existing feature PRD, update that PRD. If a change introduces a wholly new product area that does not belong in any existing PRD, create a new feature PRD. When in doubt, ask the user.
|
|
159
173
|
|
|
160
174
|
**Implementation checkboxes.** Feature PRDs use markdown checkboxes (`- [ ]` / `- [x]`) on capabilities to track implementation status for `gspec-implement`. When DOR adds new capabilities, use unchecked checkboxes (`- [ ]`). When modifying a capability that was already checked (`- [x]`) and the code change reflects the modification, keep it checked. When creating a new feature PRD, use unchecked checkboxes for all capabilities. Do not check off capabilities that DOR did not implement in the current session.
|
|
@@ -70,7 +70,8 @@ Systematically evaluate which gspec documents need updating. Apply this decision
|
|
|
70
70
|
| New technology or dependency added | `gspec/stack.md` | Add to appropriate section with rationale |
|
|
71
71
|
| Technology or dependency removed | `gspec/stack.md` | Remove and note why |
|
|
72
72
|
| Technology version changed | `gspec/stack.md` | Update version |
|
|
73
|
-
| Visual design change (colors, typography, spacing,
|
|
73
|
+
| Visual design change — generic (colors, typography, spacing, base component patterns) | `gspec/style.md` | Update affected tokens or base component patterns. Only include changes that are reusable and not tied to a specific feature or domain |
|
|
74
|
+
| Visual design change — feature-specific (a component unique to a feature, domain-specific visual treatment) | `gspec/features/<relevant>.md` | Document the visual details in the feature PRD's capabilities or a dedicated "Visual Design" subsection |
|
|
74
75
|
| Development practice change (testing, code org, conventions) | `gspec/practices.md` | Update affected practice |
|
|
75
76
|
| Product scope or direction change | `gspec/profile.md` | Update affected sections (Product Description, Use Cases, Roadmap, etc.) |
|
|
76
77
|
| Feature dependency change | `gspec/epics/<relevant>.md` | Update dependency map and phasing |
|
|
@@ -148,6 +149,8 @@ After writing spec updates:
|
|
|
148
149
|
|
|
149
150
|
**Traceability without clutter.** A brief note about why something changed is valuable for future readers. A changelog at the bottom of every file is not. Use judgment.
|
|
150
151
|
|
|
152
|
+
**Keep `style.md` generic and reusable.** The style guide defines the design system — colors, typography, spacing, base component patterns, and tokens that could apply to any product. Do not add feature-specific or domain-specific content to `style.md` (e.g., "recipe card layout", "playlist item styling"). Feature-specific visual details belong in the relevant feature PRD. If you are unsure whether a visual change is generic or feature-specific, ask the user.
|
|
153
|
+
|
|
151
154
|
**When to create vs. update.** If a change adds a small capability that fits naturally within an existing feature PRD, update that PRD. If a change introduces a wholly new product area that does not belong in any existing PRD, create a new feature PRD. When in doubt, ask the user.
|
|
152
155
|
|
|
153
156
|
**No code changes.** This command never creates, modifies, or deletes code files. If the user needs code changes alongside spec updates, suggest using `gspec-dor` instead.
|
|
@@ -63,6 +63,17 @@ Execute the code changes:
|
|
|
63
63
|
5. **Surface new issues as they arise** — If implementation reveals new ambiguities, pause and consult the user rather than making silent assumptions
|
|
64
64
|
6. **Track spec implications as you work** — As you implement, mentally note which gspec documents will need updating based on what you are changing
|
|
65
65
|
|
|
66
|
+
### Phase 3.5: Validate — Ensure Tests Pass
|
|
67
|
+
|
|
68
|
+
Before updating any specs, verify the code changes are sound:
|
|
69
|
+
|
|
70
|
+
1. **Check for existing tests** — Look for a test suite, test runner configuration, or test scripts in `package.json`, `Makefile`, or equivalent
|
|
71
|
+
2. **If tests exist, run them** — Execute the project's test suite and confirm all tests pass
|
|
72
|
+
3. **If tests fail** — Fix the failing tests before proceeding. Do not move to spec updates with a broken test suite
|
|
73
|
+
4. **If no tests exist** — Note this and proceed. Do not create a test suite unless the user requests one or `gspec/practices.md` requires it
|
|
74
|
+
|
|
75
|
+
This gate ensures specs are only updated to reflect working, validated code — never broken implementations.
|
|
76
|
+
|
|
66
77
|
### Phase 4: Assess — Determine Spec Impact
|
|
67
78
|
|
|
68
79
|
After code changes are complete, systematically evaluate which gspec documents need updating. Apply this decision matrix:
|
|
@@ -75,7 +86,8 @@ After code changes are complete, systematically evaluate which gspec documents n
|
|
|
75
86
|
| New technology or dependency added | `gspec/stack.md` | Add to appropriate section with rationale |
|
|
76
87
|
| Technology or dependency removed | `gspec/stack.md` | Remove and note why |
|
|
77
88
|
| Technology version changed | `gspec/stack.md` | Update version |
|
|
78
|
-
| Visual design change (colors, typography, spacing,
|
|
89
|
+
| Visual design change — generic (colors, typography, spacing, base component patterns) | `gspec/style.md` | Update affected tokens or base component patterns. Only include changes that are reusable and not tied to a specific feature or domain |
|
|
90
|
+
| Visual design change — feature-specific (a component unique to a feature, domain-specific visual treatment) | `gspec/features/<relevant>.md` | Document the visual details in the feature PRD's capabilities or a dedicated "Visual Design" subsection |
|
|
79
91
|
| Development practice change (testing, code org, conventions) | `gspec/practices.md` | Update affected practice |
|
|
80
92
|
| Product scope or direction change | `gspec/profile.md` | Update affected sections (Product Description, Use Cases, Roadmap, etc.) |
|
|
81
93
|
| Feature dependency change | `gspec/epics/<relevant>.md` | Update dependency map and phasing |
|
|
@@ -155,6 +167,8 @@ After writing spec updates:
|
|
|
155
167
|
|
|
156
168
|
**Traceability without clutter.** A brief note about why something changed is valuable for future readers. A changelog at the bottom of every file is not. Use judgment. For small, obvious changes, no annotation may be needed. For significant scope changes, a parenthetical note aids understanding.
|
|
157
169
|
|
|
170
|
+
**Keep `style.md` generic and reusable.** The style guide defines the design system — colors, typography, spacing, base component patterns, and tokens that could apply to any product. Do not add feature-specific or domain-specific content to `style.md` (e.g., "recipe card layout", "playlist item styling"). Feature-specific visual details belong in the relevant feature PRD. If you are unsure whether a visual change is generic or feature-specific, ask the user.
|
|
171
|
+
|
|
158
172
|
**When to create vs. update.** If a change adds a small capability that fits naturally within an existing feature PRD, update that PRD. If a change introduces a wholly new product area that does not belong in any existing PRD, create a new feature PRD. When in doubt, ask the user.
|
|
159
173
|
|
|
160
174
|
**Implementation checkboxes.** Feature PRDs use markdown checkboxes (`- [ ]` / `- [x]`) on capabilities to track implementation status for `gspec-implement`. When DOR adds new capabilities, use unchecked checkboxes (`- [ ]`). When modifying a capability that was already checked (`- [x]`) and the code change reflects the modification, keep it checked. When creating a new feature PRD, use unchecked checkboxes for all capabilities. Do not check off capabilities that DOR did not implement in the current session.
|
|
@@ -70,7 +70,8 @@ Systematically evaluate which gspec documents need updating. Apply this decision
|
|
|
70
70
|
| New technology or dependency added | `gspec/stack.md` | Add to appropriate section with rationale |
|
|
71
71
|
| Technology or dependency removed | `gspec/stack.md` | Remove and note why |
|
|
72
72
|
| Technology version changed | `gspec/stack.md` | Update version |
|
|
73
|
-
| Visual design change (colors, typography, spacing,
|
|
73
|
+
| Visual design change — generic (colors, typography, spacing, base component patterns) | `gspec/style.md` | Update affected tokens or base component patterns. Only include changes that are reusable and not tied to a specific feature or domain |
|
|
74
|
+
| Visual design change — feature-specific (a component unique to a feature, domain-specific visual treatment) | `gspec/features/<relevant>.md` | Document the visual details in the feature PRD's capabilities or a dedicated "Visual Design" subsection |
|
|
74
75
|
| Development practice change (testing, code org, conventions) | `gspec/practices.md` | Update affected practice |
|
|
75
76
|
| Product scope or direction change | `gspec/profile.md` | Update affected sections (Product Description, Use Cases, Roadmap, etc.) |
|
|
76
77
|
| Feature dependency change | `gspec/epics/<relevant>.md` | Update dependency map and phasing |
|
|
@@ -148,6 +149,8 @@ After writing spec updates:
|
|
|
148
149
|
|
|
149
150
|
**Traceability without clutter.** A brief note about why something changed is valuable for future readers. A changelog at the bottom of every file is not. Use judgment.
|
|
150
151
|
|
|
152
|
+
**Keep `style.md` generic and reusable.** The style guide defines the design system — colors, typography, spacing, base component patterns, and tokens that could apply to any product. Do not add feature-specific or domain-specific content to `style.md` (e.g., "recipe card layout", "playlist item styling"). Feature-specific visual details belong in the relevant feature PRD. If you are unsure whether a visual change is generic or feature-specific, ask the user.
|
|
153
|
+
|
|
151
154
|
**When to create vs. update.** If a change adds a small capability that fits naturally within an existing feature PRD, update that PRD. If a change introduces a wholly new product area that does not belong in any existing PRD, create a new feature PRD. When in doubt, ask the user.
|
|
152
155
|
|
|
153
156
|
**No code changes.** This command never creates, modifies, or deletes code files. If the user needs code changes alongside spec updates, suggest using `gspec-dor` instead.
|
|
@@ -62,6 +62,17 @@ Execute the code changes:
|
|
|
62
62
|
5. **Surface new issues as they arise** — If implementation reveals new ambiguities, pause and consult the user rather than making silent assumptions
|
|
63
63
|
6. **Track spec implications as you work** — As you implement, mentally note which gspec documents will need updating based on what you are changing
|
|
64
64
|
|
|
65
|
+
### Phase 3.5: Validate — Ensure Tests Pass
|
|
66
|
+
|
|
67
|
+
Before updating any specs, verify the code changes are sound:
|
|
68
|
+
|
|
69
|
+
1. **Check for existing tests** — Look for a test suite, test runner configuration, or test scripts in `package.json`, `Makefile`, or equivalent
|
|
70
|
+
2. **If tests exist, run them** — Execute the project's test suite and confirm all tests pass
|
|
71
|
+
3. **If tests fail** — Fix the failing tests before proceeding. Do not move to spec updates with a broken test suite
|
|
72
|
+
4. **If no tests exist** — Note this and proceed. Do not create a test suite unless the user requests one or `gspec/practices.md` requires it
|
|
73
|
+
|
|
74
|
+
This gate ensures specs are only updated to reflect working, validated code — never broken implementations.
|
|
75
|
+
|
|
65
76
|
### Phase 4: Assess — Determine Spec Impact
|
|
66
77
|
|
|
67
78
|
After code changes are complete, systematically evaluate which gspec documents need updating. Apply this decision matrix:
|
|
@@ -74,7 +85,8 @@ After code changes are complete, systematically evaluate which gspec documents n
|
|
|
74
85
|
| New technology or dependency added | `gspec/stack.md` | Add to appropriate section with rationale |
|
|
75
86
|
| Technology or dependency removed | `gspec/stack.md` | Remove and note why |
|
|
76
87
|
| Technology version changed | `gspec/stack.md` | Update version |
|
|
77
|
-
| Visual design change (colors, typography, spacing,
|
|
88
|
+
| Visual design change — generic (colors, typography, spacing, base component patterns) | `gspec/style.md` | Update affected tokens or base component patterns. Only include changes that are reusable and not tied to a specific feature or domain |
|
|
89
|
+
| Visual design change — feature-specific (a component unique to a feature, domain-specific visual treatment) | `gspec/features/<relevant>.md` | Document the visual details in the feature PRD's capabilities or a dedicated "Visual Design" subsection |
|
|
78
90
|
| Development practice change (testing, code org, conventions) | `gspec/practices.md` | Update affected practice |
|
|
79
91
|
| Product scope or direction change | `gspec/profile.md` | Update affected sections (Product Description, Use Cases, Roadmap, etc.) |
|
|
80
92
|
| Feature dependency change | `gspec/epics/<relevant>.md` | Update dependency map and phasing |
|
|
@@ -154,6 +166,8 @@ After writing spec updates:
|
|
|
154
166
|
|
|
155
167
|
**Traceability without clutter.** A brief note about why something changed is valuable for future readers. A changelog at the bottom of every file is not. Use judgment. For small, obvious changes, no annotation may be needed. For significant scope changes, a parenthetical note aids understanding.
|
|
156
168
|
|
|
169
|
+
**Keep `style.md` generic and reusable.** The style guide defines the design system — colors, typography, spacing, base component patterns, and tokens that could apply to any product. Do not add feature-specific or domain-specific content to `style.md` (e.g., "recipe card layout", "playlist item styling"). Feature-specific visual details belong in the relevant feature PRD. If you are unsure whether a visual change is generic or feature-specific, ask the user.
|
|
170
|
+
|
|
157
171
|
**When to create vs. update.** If a change adds a small capability that fits naturally within an existing feature PRD, update that PRD. If a change introduces a wholly new product area that does not belong in any existing PRD, create a new feature PRD. When in doubt, ask the user.
|
|
158
172
|
|
|
159
173
|
**Implementation checkboxes.** Feature PRDs use markdown checkboxes (`- [ ]` / `- [x]`) on capabilities to track implementation status for `gspec-implement`. When DOR adds new capabilities, use unchecked checkboxes (`- [ ]`). When modifying a capability that was already checked (`- [x]`) and the code change reflects the modification, keep it checked. When creating a new feature PRD, use unchecked checkboxes for all capabilities. Do not check off capabilities that DOR did not implement in the current session.
|
|
@@ -69,7 +69,8 @@ Systematically evaluate which gspec documents need updating. Apply this decision
|
|
|
69
69
|
| New technology or dependency added | `gspec/stack.md` | Add to appropriate section with rationale |
|
|
70
70
|
| Technology or dependency removed | `gspec/stack.md` | Remove and note why |
|
|
71
71
|
| Technology version changed | `gspec/stack.md` | Update version |
|
|
72
|
-
| Visual design change (colors, typography, spacing,
|
|
72
|
+
| Visual design change — generic (colors, typography, spacing, base component patterns) | `gspec/style.md` | Update affected tokens or base component patterns. Only include changes that are reusable and not tied to a specific feature or domain |
|
|
73
|
+
| Visual design change — feature-specific (a component unique to a feature, domain-specific visual treatment) | `gspec/features/<relevant>.md` | Document the visual details in the feature PRD's capabilities or a dedicated "Visual Design" subsection |
|
|
73
74
|
| Development practice change (testing, code org, conventions) | `gspec/practices.md` | Update affected practice |
|
|
74
75
|
| Product scope or direction change | `gspec/profile.md` | Update affected sections (Product Description, Use Cases, Roadmap, etc.) |
|
|
75
76
|
| Feature dependency change | `gspec/epics/<relevant>.md` | Update dependency map and phasing |
|
|
@@ -147,6 +148,8 @@ After writing spec updates:
|
|
|
147
148
|
|
|
148
149
|
**Traceability without clutter.** A brief note about why something changed is valuable for future readers. A changelog at the bottom of every file is not. Use judgment.
|
|
149
150
|
|
|
151
|
+
**Keep `style.md` generic and reusable.** The style guide defines the design system — colors, typography, spacing, base component patterns, and tokens that could apply to any product. Do not add feature-specific or domain-specific content to `style.md` (e.g., "recipe card layout", "playlist item styling"). Feature-specific visual details belong in the relevant feature PRD. If you are unsure whether a visual change is generic or feature-specific, ask the user.
|
|
152
|
+
|
|
150
153
|
**When to create vs. update.** If a change adds a small capability that fits naturally within an existing feature PRD, update that PRD. If a change introduces a wholly new product area that does not belong in any existing PRD, create a new feature PRD. When in doubt, ask the user.
|
|
151
154
|
|
|
152
155
|
**No code changes.** This command never creates, modifies, or deletes code files. If the user needs code changes alongside spec updates, suggest using `gspec-dor` instead.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "gspec",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.3",
|
|
4
4
|
"description": "Install gspec specification commands for Claude Code, Cursor, and other AI tools",
|
|
5
5
|
"main": "bin/gspec.js",
|
|
6
6
|
"type": "module",
|
|
@@ -19,8 +19,11 @@
|
|
|
19
19
|
"build:antigravity": "node scripts/build.js antigravity",
|
|
20
20
|
"prepublishOnly": "npm run build"
|
|
21
21
|
},
|
|
22
|
-
"author": "",
|
|
23
|
-
"
|
|
22
|
+
"author": "Baller Software",
|
|
23
|
+
"repository": {
|
|
24
|
+
"url": "https://github.com/gballer77/gspec"
|
|
25
|
+
},
|
|
26
|
+
"license": "MIT",
|
|
24
27
|
"dependencies": {
|
|
25
28
|
"chalk": "^5.6.2",
|
|
26
29
|
"commander": "^11.1.0"
|