@ahmed118glitch/get-shit-done-codex 1.18.4 → 1.19.2

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.
Files changed (36) hide show
  1. package/CHANGELOG.md +33 -1
  2. package/agents/gsd-phase-researcher.md +1 -1
  3. package/agents/gsd-roadmapper.md +39 -5
  4. package/agents/gsd-verifier.md +20 -4
  5. package/bin/install-codex.js +1 -1
  6. package/bin/install.js +65 -8
  7. package/commands/gsd/discuss-phase.md +3 -2
  8. package/commands/gsd/plan-phase.md +1 -1
  9. package/commands/gsd/reapply-patches.md +3 -3
  10. package/commands/gsd/verify-work.md +1 -1
  11. package/get-shit-done/bin/gsd-tools.js +222 -20
  12. package/get-shit-done/bin/gsd-tools.test.js +189 -0
  13. package/get-shit-done/references/model-profile-resolution.md +4 -2
  14. package/get-shit-done/references/model-profiles.md +3 -0
  15. package/get-shit-done/references/questioning.md +1 -0
  16. package/get-shit-done/templates/UAT.md +1 -1
  17. package/get-shit-done/templates/config.json +2 -1
  18. package/get-shit-done/templates/context.md +2 -2
  19. package/get-shit-done/templates/planner-subagent-prompt.md +4 -4
  20. package/get-shit-done/templates/research.md +2 -2
  21. package/get-shit-done/templates/verification-report.md +1 -1
  22. package/get-shit-done/workflows/diagnose-issues.md +1 -1
  23. package/get-shit-done/workflows/discovery-phase.md +1 -1
  24. package/get-shit-done/workflows/discuss-phase.md +64 -3
  25. package/get-shit-done/workflows/execute-phase.md +68 -20
  26. package/get-shit-done/workflows/execute-plan.md +4 -1
  27. package/get-shit-done/workflows/new-milestone.md +1 -1
  28. package/get-shit-done/workflows/new-project.md +3 -3
  29. package/get-shit-done/workflows/plan-phase.md +54 -2
  30. package/get-shit-done/workflows/progress.md +2 -2
  31. package/get-shit-done/workflows/settings.md +13 -2
  32. package/get-shit-done/workflows/transition.md +48 -2
  33. package/get-shit-done/workflows/update.md +4 -2
  34. package/get-shit-done/workflows/verify-phase.md +18 -2
  35. package/get-shit-done/workflows/verify-work.md +3 -3
  36. package/package.json +1 -1
package/CHANGELOG.md CHANGED
@@ -6,6 +6,36 @@ Format follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/).
6
6
 
7
7
  ## [Unreleased]
8
8
 
9
+ ## [1.19.1] - 2026-02-15
10
+
11
+ ### Added
12
+ - Auto-advance pipeline: `--auto` flag on `discuss-phase` and `plan-phase` chains discuss → plan → execute without stopping. Also available as `workflow.auto_advance` config setting
13
+
14
+ ### Fixed
15
+ - Phase transition routing now routes to `discuss-phase` (not `plan-phase`) when no CONTEXT.md exists — consistent across all workflows (#530)
16
+ - ROADMAP progress table plan counts are now computed from disk instead of LLM-edited — deterministic "X/Y Complete" values (#537)
17
+ - Verifier uses ROADMAP Success Criteria directly instead of deriving verification truths from the Goal field (#538)
18
+ - REQUIREMENTS.md traceability updates when a phase completes
19
+ - STATE.md updates after discuss-phase completes (#556)
20
+ - AskUserQuestion headers enforced to 12-char max to prevent UI truncation (#559)
21
+ - Agent model resolution returns `inherit` instead of hardcoded `opus` (#558)
22
+
23
+ ## [1.19.0] - 2026-02-15
24
+
25
+ ### Added
26
+ - Brave Search integration for researchers (requires BRAVE_API_KEY environment variable)
27
+ - GitHub issue templates for bug reports and feature requests
28
+ - Security policy for responsible disclosure
29
+ - Auto-labeling workflow for new issues
30
+
31
+ ### Fixed
32
+ - UAT gaps and debug sessions now auto-resolve after gap-closure phase execution (#580)
33
+ - Fall back to ROADMAP.md when phase directory missing (#521)
34
+ - Template hook paths for OpenCode/Gemini runtimes (#585)
35
+ - Accept both `##` and `###` phase headers, detect malformed ROADMAPs (#598, #599)
36
+ - Use `{phase_num}` instead of ambiguous `{phase}` for filenames (#601)
37
+ - Add package.json to prevent ESM inheritance issues (#602)
38
+
9
39
  ## [1.18.0] - 2026-02-08
10
40
 
11
41
  ### Added
@@ -1206,7 +1236,9 @@ Format follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/).
1206
1236
  - YOLO mode for autonomous execution
1207
1237
  - Interactive mode with checkpoints
1208
1238
 
1209
- [Unreleased]: https://github.com/glittercowboy/get-shit-done/compare/v1.18.0...HEAD
1239
+ [Unreleased]: https://github.com/glittercowboy/get-shit-done/compare/v1.19.1...HEAD
1240
+ [1.19.1]: https://github.com/glittercowboy/get-shit-done/releases/tag/v1.19.1
1241
+ [1.19.0]: https://github.com/glittercowboy/get-shit-done/releases/tag/v1.19.0
1210
1242
  [1.18.0]: https://github.com/glittercowboy/get-shit-done/releases/tag/v1.18.0
1211
1243
  [1.17.0]: https://github.com/glittercowboy/get-shit-done/releases/tag/v1.17.0
1212
1244
  [1.16.0]: https://github.com/glittercowboy/get-shit-done/releases/tag/v1.16.0
@@ -177,7 +177,7 @@ Priority: Context7 > Official Docs > Official GitHub > Verified WebSearch > Unve
177
177
 
178
178
  ## RESEARCH.md Structure
179
179
 
180
- **Location:** `.planning/phases/XX-name/{phase}-RESEARCH.md`
180
+ **Location:** `.planning/phases/XX-name/{phase_num}-RESEARCH.md`
181
181
 
182
182
  ```markdown
183
183
  # Phase [X]: [Name] - Research
@@ -286,12 +286,46 @@ After roadmap creation, REQUIREMENTS.md gets updated with phase mappings:
286
286
 
287
287
  ## ROADMAP.md Structure
288
288
 
289
- Use template from `~/.claude/get-shit-done/templates/roadmap.md`.
289
+ **CRITICAL: ROADMAP.md requires TWO phase representations. Both are mandatory.**
290
290
 
291
- Key sections:
292
- - Overview (2-3 sentences)
293
- - Phases with Goal, Dependencies, Requirements, Success Criteria
294
- - Progress table
291
+ ### 1. Summary Checklist (under `## Phases`)
292
+
293
+ ```markdown
294
+ - [ ] **Phase 1: Name** - One-line description
295
+ - [ ] **Phase 2: Name** - One-line description
296
+ - [ ] **Phase 3: Name** - One-line description
297
+ ```
298
+
299
+ ### 2. Detail Sections (under `## Phase Details`)
300
+
301
+ ```markdown
302
+ ### Phase 1: Name
303
+ **Goal**: What this phase delivers
304
+ **Depends on**: Nothing (first phase)
305
+ **Requirements**: REQ-01, REQ-02
306
+ **Success Criteria** (what must be TRUE):
307
+ 1. Observable behavior from user perspective
308
+ 2. Observable behavior from user perspective
309
+ **Plans**: TBD
310
+
311
+ ### Phase 2: Name
312
+ **Goal**: What this phase delivers
313
+ **Depends on**: Phase 1
314
+ ...
315
+ ```
316
+
317
+ **The `### Phase X:` headers are parsed by downstream tools.** If you only write the summary checklist, phase lookups will fail.
318
+
319
+ ### 3. Progress Table
320
+
321
+ ```markdown
322
+ | Phase | Plans Complete | Status | Completed |
323
+ |-------|----------------|--------|-----------|
324
+ | 1. Name | 0/3 | Not started | - |
325
+ | 2. Name | 0/2 | Not started | - |
326
+ ```
327
+
328
+ Reference full template: `~/.claude/get-shit-done/templates/roadmap.md`
295
329
 
296
330
  ## STATE.md Structure
297
331
 
@@ -86,9 +86,25 @@ must_haves:
86
86
  via: "fetch in useEffect"
87
87
  ```
88
88
 
89
- **Option B: Derive from phase goal**
89
+ **Option B: Use Success Criteria from ROADMAP.md**
90
90
 
91
- If no must_haves in frontmatter:
91
+ If no must_haves in frontmatter, check for Success Criteria:
92
+
93
+ ```bash
94
+ PHASE_DATA=$(node ~/.claude/get-shit-done/bin/gsd-tools.js roadmap get-phase "$PHASE_NUM" --raw)
95
+ ```
96
+
97
+ Parse the `success_criteria` array from the JSON output. If non-empty:
98
+ 1. **Use each Success Criterion directly as a truth** (they are already observable, testable behaviors)
99
+ 2. **Derive artifacts:** For each truth, "What must EXIST?" — map to concrete file paths
100
+ 3. **Derive key links:** For each artifact, "What must be CONNECTED?" — this is where stubs hide
101
+ 4. **Document must-haves** before proceeding
102
+
103
+ Success Criteria from ROADMAP.md are the contract — they take priority over Goal-derived truths.
104
+
105
+ **Option C: Derive from phase goal (fallback)**
106
+
107
+ If no must_haves in frontmatter AND no Success Criteria in ROADMAP:
92
108
 
93
109
  1. **State the goal** from ROADMAP.md
94
110
  2. **Derive truths:** "What must be TRUE?" — list 3-7 observable, testable behaviors
@@ -317,7 +333,7 @@ gaps:
317
333
 
318
334
  ## Create VERIFICATION.md
319
335
 
320
- Create `.planning/phases/{phase_dir}/{phase}-VERIFICATION.md`:
336
+ Create `.planning/phases/{phase_dir}/{phase_num}-VERIFICATION.md`:
321
337
 
322
338
  ```markdown
323
339
  ---
@@ -411,7 +427,7 @@ Return with:
411
427
 
412
428
  **Status:** {passed | gaps_found | human_needed}
413
429
  **Score:** {N}/{M} must-haves verified
414
- **Report:** .planning/phases/{phase_dir}/{phase}-VERIFICATION.md
430
+ **Report:** .planning/phases/{phase_dir}/{phase_num}-VERIFICATION.md
415
431
 
416
432
  {If passed:}
417
433
  All must-haves verified. Phase goal achieved. Ready to proceed.
@@ -89,7 +89,7 @@ if (installGlobal) {
89
89
  copyCodexToDirectory(globalBase);
90
90
  }
91
91
 
92
- console.log(`\n${pkg.name} installed to:`);
92
+ console.log(`\n${pkg.name}@${pkg.version} installed to:`);
93
93
  console.log(` local: ${targetDir}`);
94
94
  if (installGlobal) {
95
95
  console.log(' global: ~/.codex');
package/bin/install.js CHANGED
@@ -1,4 +1,4 @@
1
- #!/usr/bin/env node
1
+ #!/usr/bin/env node
2
2
 
3
3
  const fs = require('fs');
4
4
  const path = require('path');
@@ -46,6 +46,27 @@ function getDirName(runtime) {
46
46
  return '.claude';
47
47
  }
48
48
 
49
+ /**
50
+ * Get the config directory path relative to home directory for a runtime
51
+ * Used for templating hooks that use path.join(homeDir, '<configDir>', ...)
52
+ * @param {string} runtime - 'claude', 'opencode', or 'gemini'
53
+ * @param {boolean} isGlobal - Whether this is a global install
54
+ */
55
+ function getConfigDirFromHome(runtime, isGlobal) {
56
+ if (!isGlobal) {
57
+ // Local installs use the same dir name pattern
58
+ return getDirName(runtime);
59
+ }
60
+ // Global installs - OpenCode uses XDG path structure
61
+ if (runtime === 'opencode') {
62
+ // OpenCode: ~/.config/opencode -> '.config', 'opencode'
63
+ // Return as comma-separated for path.join() replacement
64
+ return "'.config', 'opencode'";
65
+ }
66
+ if (runtime === 'gemini') return "'.gemini'";
67
+ return "'.claude'";
68
+ }
69
+
49
70
  /**
50
71
  * Get the global config directory for OpenCode
51
72
  * OpenCode follows XDG Base Directory spec and uses ~/.config/opencode/
@@ -626,9 +647,11 @@ function copyFlattenedCommands(srcDir, destDir, prefix, pathPrefix, runtime) {
626
647
  const destPath = path.join(destDir, destName);
627
648
 
628
649
  let content = fs.readFileSync(srcPath, 'utf8');
629
- const claudeDirRegex = /~\/\.claude\//g;
650
+ const globalClaudeRegex = /~\/\.claude\//g;
651
+ const localClaudeRegex = /\.\/\.claude\//g;
630
652
  const opencodeDirRegex = /~\/\.opencode\//g;
631
- content = content.replace(claudeDirRegex, pathPrefix);
653
+ content = content.replace(globalClaudeRegex, pathPrefix);
654
+ content = content.replace(localClaudeRegex, `./${getDirName(runtime)}/`);
632
655
  content = content.replace(opencodeDirRegex, pathPrefix);
633
656
  content = processAttribution(content, getCommitAttribution(runtime));
634
657
  content = convertClaudeToOpencodeFrontmatter(content);
@@ -665,10 +688,12 @@ function copyWithPathReplacement(srcDir, destDir, pathPrefix, runtime) {
665
688
  if (entry.isDirectory()) {
666
689
  copyWithPathReplacement(srcPath, destPath, pathPrefix, runtime);
667
690
  } else if (entry.name.endsWith('.md')) {
668
- // Always replace ~/.claude/ as it is the source of truth in the repo
691
+ // Replace ~/.claude/ and ./.claude/ with runtime-appropriate paths
669
692
  let content = fs.readFileSync(srcPath, 'utf8');
670
- const claudeDirRegex = /~\/\.claude\//g;
671
- content = content.replace(claudeDirRegex, pathPrefix);
693
+ const globalClaudeRegex = /~\/\.claude\//g;
694
+ const localClaudeRegex = /\.\/\.claude\//g;
695
+ content = content.replace(globalClaudeRegex, pathPrefix);
696
+ content = content.replace(localClaudeRegex, `./${dirName}/`);
672
697
  content = processAttribution(content, getCommitAttribution(runtime));
673
698
 
674
699
  // Convert frontmatter for opencode compatibility
@@ -867,7 +892,23 @@ function uninstall(isGlobal, runtime = 'claude') {
867
892
  }
868
893
  }
869
894
 
870
- // 5. Clean up settings.json (remove GSD hooks and statusline)
895
+ // 5. Remove GSD package.json (CommonJS mode marker)
896
+ const pkgJsonPath = path.join(targetDir, 'package.json');
897
+ if (fs.existsSync(pkgJsonPath)) {
898
+ try {
899
+ const content = fs.readFileSync(pkgJsonPath, 'utf8').trim();
900
+ // Only remove if it's our minimal CommonJS marker
901
+ if (content === '{"type":"commonjs"}') {
902
+ fs.unlinkSync(pkgJsonPath);
903
+ removedCount++;
904
+ console.log(` ${green}✓${reset} Removed GSD package.json`);
905
+ }
906
+ } catch (e) {
907
+ // Ignore read errors
908
+ }
909
+ }
910
+
911
+ // 6. Clean up settings.json (remove GSD hooks and statusline)
871
912
  const settingsPath = path.join(targetDir, 'settings.json');
872
913
  if (fs.existsSync(settingsPath)) {
873
914
  let settings = readSettings(settingsPath);
@@ -1405,17 +1446,33 @@ function install(isGlobal, runtime = 'claude') {
1405
1446
  failures.push('VERSION');
1406
1447
  }
1407
1448
 
1449
+ // Write package.json to force CommonJS mode for GSD scripts
1450
+ // Prevents "require is not defined" errors when project has "type": "module"
1451
+ // Node.js walks up looking for package.json - this stops inheritance from project
1452
+ const pkgJsonDest = path.join(targetDir, 'package.json');
1453
+ fs.writeFileSync(pkgJsonDest, '{"type":"commonjs"}\n');
1454
+ console.log(` ${green}✓${reset} Wrote package.json (CommonJS mode)`);
1455
+
1408
1456
  // Copy hooks from dist/ (bundled with dependencies)
1457
+ // Template paths for the target runtime (replaces '.claude' with correct config dir)
1409
1458
  const hooksSrc = path.join(src, 'hooks', 'dist');
1410
1459
  if (fs.existsSync(hooksSrc)) {
1411
1460
  const hooksDest = path.join(targetDir, 'hooks');
1412
1461
  fs.mkdirSync(hooksDest, { recursive: true });
1413
1462
  const hookEntries = fs.readdirSync(hooksSrc);
1463
+ const configDirReplacement = getConfigDirFromHome(runtime, isGlobal);
1414
1464
  for (const entry of hookEntries) {
1415
1465
  const srcFile = path.join(hooksSrc, entry);
1416
1466
  if (fs.statSync(srcFile).isFile()) {
1417
1467
  const destFile = path.join(hooksDest, entry);
1418
- fs.copyFileSync(srcFile, destFile);
1468
+ // Template .js files to replace '.claude' with runtime-specific config dir
1469
+ if (entry.endsWith('.js')) {
1470
+ let content = fs.readFileSync(srcFile, 'utf8');
1471
+ content = content.replace(/'\.claude'/g, configDirReplacement);
1472
+ fs.writeFileSync(destFile, content);
1473
+ } else {
1474
+ fs.copyFileSync(srcFile, destFile);
1475
+ }
1419
1476
  }
1420
1477
  }
1421
1478
  if (verifyInstalled(hooksDest, 'hooks')) {
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  name: gsd:discuss-phase
3
3
  description: Gather phase context through adaptive questioning before planning
4
- argument-hint: "<phase>"
4
+ argument-hint: "<phase> [--auto]"
5
5
  allowed-tools:
6
6
  - Read
7
7
  - Write
@@ -9,6 +9,7 @@ allowed-tools:
9
9
  - Glob
10
10
  - Grep
11
11
  - AskUserQuestion
12
+ - Task
12
13
  ---
13
14
 
14
15
  <objective>
@@ -20,7 +21,7 @@ Extract implementation decisions that downstream agents need — researcher and
20
21
  3. Deep-dive each selected area until satisfied
21
22
  4. Create CONTEXT.md with decisions that guide research and planning
22
23
 
23
- **Output:** `{phase}-CONTEXT.md` — decisions clear enough that downstream agents can act without asking the user again
24
+ **Output:** `{phase_num}-CONTEXT.md` — decisions clear enough that downstream agents can act without asking the user again
24
25
  </objective>
25
26
 
26
27
  <execution_context>
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  name: gsd:plan-phase
3
3
  description: Create detailed execution plan for a phase (PLAN.md) with verification loop
4
- argument-hint: "[phase] [--research] [--skip-research] [--gaps] [--skip-verify]"
4
+ argument-hint: "[phase] [--auto] [--research] [--skip-research] [--gaps] [--skip-verify]"
5
5
  agent: gsd-planner
6
6
  allowed-tools:
7
7
  - Read
@@ -14,11 +14,11 @@ After a GSD update wipes and reinstalls files, this command merges user's previo
14
14
  Check for local patches directory:
15
15
 
16
16
  ```bash
17
- # Global install
18
- PATCHES_DIR="${HOME}/.claude/gsd-local-patches"
17
+ # Global install (path templated at install time)
18
+ PATCHES_DIR=~/.claude/gsd-local-patches
19
19
  # Local install fallback
20
20
  if [ ! -d "$PATCHES_DIR" ]; then
21
- PATCHES_DIR="./.claude/gsd-local-patches"
21
+ PATCHES_DIR=./.claude/gsd-local-patches
22
22
  fi
23
23
  ```
24
24
 
@@ -16,7 +16,7 @@ Validate built features through conversational testing with persistent state.
16
16
 
17
17
  Purpose: Confirm what Claude built actually works from user's perspective. One test at a time, plain text responses, no interrogation. When issues are found, automatically diagnose, plan fixes, and prepare for execution.
18
18
 
19
- Output: {phase}-UAT.md tracking all test results. If issues found: diagnosed gaps, verified fix plans ready for /gsd:execute-phase
19
+ Output: {phase_num}-UAT.md tracking all test results. If issues found: diagnosed gaps, verified fix plans ready for /gsd:execute-phase
20
20
  </objective>
21
21
 
22
22
  <execution_context>