opengstack 0.13.4

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 (73) hide show
  1. package/AGENTS.md +47 -0
  2. package/CLAUDE.md +370 -0
  3. package/LICENSE +21 -0
  4. package/README.md +80 -0
  5. package/SKILL.md +226 -0
  6. package/autoplan/SKILL.md +96 -0
  7. package/autoplan/SKILL.md.tmpl +694 -0
  8. package/benchmark/SKILL.md +358 -0
  9. package/benchmark/SKILL.md.tmpl +222 -0
  10. package/browse/SKILL.md +396 -0
  11. package/browse/SKILL.md.tmpl +131 -0
  12. package/canary/SKILL.md +89 -0
  13. package/canary/SKILL.md.tmpl +212 -0
  14. package/careful/SKILL.md +58 -0
  15. package/careful/SKILL.md.tmpl +56 -0
  16. package/codex/SKILL.md +90 -0
  17. package/codex/SKILL.md.tmpl +417 -0
  18. package/connect-chrome/SKILL.md +87 -0
  19. package/connect-chrome/SKILL.md.tmpl +195 -0
  20. package/cso/SKILL.md +93 -0
  21. package/cso/SKILL.md.tmpl +606 -0
  22. package/design-consultation/SKILL.md +94 -0
  23. package/design-consultation/SKILL.md.tmpl +415 -0
  24. package/design-review/SKILL.md +94 -0
  25. package/design-review/SKILL.md.tmpl +290 -0
  26. package/design-shotgun/SKILL.md +91 -0
  27. package/design-shotgun/SKILL.md.tmpl +285 -0
  28. package/docs/designs/CHROME_VS_CHROMIUM_EXPLORATION.md +84 -0
  29. package/docs/designs/CONDUCTOR_CHROME_SIDEBAR_INTEGRATION.md +57 -0
  30. package/docs/designs/CONDUCTOR_SESSION_API.md +108 -0
  31. package/docs/designs/DESIGN_SHOTGUN.md +451 -0
  32. package/docs/designs/DESIGN_TOOLS_V1.md +622 -0
  33. package/docs/skills.md +880 -0
  34. package/document-release/SKILL.md +91 -0
  35. package/document-release/SKILL.md.tmpl +359 -0
  36. package/freeze/SKILL.md +78 -0
  37. package/freeze/SKILL.md.tmpl +77 -0
  38. package/gstack-upgrade/SKILL.md +224 -0
  39. package/gstack-upgrade/SKILL.md.tmpl +222 -0
  40. package/guard/SKILL.md +78 -0
  41. package/guard/SKILL.md.tmpl +77 -0
  42. package/investigate/SKILL.md +105 -0
  43. package/investigate/SKILL.md.tmpl +194 -0
  44. package/land-and-deploy/SKILL.md +88 -0
  45. package/land-and-deploy/SKILL.md.tmpl +881 -0
  46. package/office-hours/SKILL.md +96 -0
  47. package/office-hours/SKILL.md.tmpl +645 -0
  48. package/package.json +43 -0
  49. package/plan-ceo-review/SKILL.md +94 -0
  50. package/plan-ceo-review/SKILL.md.tmpl +811 -0
  51. package/plan-design-review/SKILL.md +92 -0
  52. package/plan-design-review/SKILL.md.tmpl +446 -0
  53. package/plan-eng-review/SKILL.md +93 -0
  54. package/plan-eng-review/SKILL.md.tmpl +303 -0
  55. package/qa/SKILL.md +95 -0
  56. package/qa/SKILL.md.tmpl +316 -0
  57. package/qa-only/SKILL.md +89 -0
  58. package/qa-only/SKILL.md.tmpl +101 -0
  59. package/retro/SKILL.md +89 -0
  60. package/retro/SKILL.md.tmpl +820 -0
  61. package/review/SKILL.md +92 -0
  62. package/review/SKILL.md.tmpl +281 -0
  63. package/scripts/cleanup.py +100 -0
  64. package/scripts/filter-skills.sh +114 -0
  65. package/scripts/filter_skills.py +140 -0
  66. package/setup-browser-cookies/SKILL.md +216 -0
  67. package/setup-browser-cookies/SKILL.md.tmpl +81 -0
  68. package/setup-deploy/SKILL.md +92 -0
  69. package/setup-deploy/SKILL.md.tmpl +215 -0
  70. package/ship/SKILL.md +90 -0
  71. package/ship/SKILL.md.tmpl +636 -0
  72. package/unfreeze/SKILL.md +37 -0
  73. package/unfreeze/SKILL.md.tmpl +36 -0
@@ -0,0 +1,636 @@
1
+ ---
2
+ name: ship
3
+ preamble-tier: 4
4
+ version: 1.0.0
5
+ description: |
6
+ Ship workflow: detect + merge base branch, run tests, review diff, bump VERSION, update CHANGELOG, commit, push, create PR. Use when asked to "ship", "deploy", "push to main", "create a PR", or "merge and push".
7
+ Proactively suggest when the user says code is ready or asks about deploying.
8
+ allowed-tools:
9
+ - Bash
10
+ - Read
11
+ - Write
12
+ - Edit
13
+ - Grep
14
+ - Glob
15
+ - Agent
16
+ - AskUserQuestion
17
+ - WebSearch
18
+ ---
19
+
20
+ {{PREAMBLE}}
21
+
22
+ {{BASE_BRANCH_DETECT}}
23
+
24
+ # Ship: Fully Automated Ship Workflow
25
+
26
+ You are running the `/ship` workflow. This is a **non-interactive, fully automated** workflow. Do NOT ask for confirmation at any step. The user said `/ship` which means DO IT. Run straight through and output the PR URL at the end.
27
+
28
+ **Only stop for:**
29
+ - On the base branch (abort)
30
+ - Merge conflicts that can't be auto-resolved (stop, show conflicts)
31
+ - In-branch test failures (pre-existing failures are triaged, not auto-blocking)
32
+ - Pre-landing review finds ASK items that need user judgment
33
+ - MINOR or MAJOR version bump needed (ask — see Step 4)
34
+ - Greptile review comments that need user decision (complex fixes, false positives)
35
+ - AI-assessed coverage below minimum threshold (hard gate with user override — see Step 3.4)
36
+ - Plan items NOT DONE with no user override (see Step 3.45)
37
+ - Plan verification failures (see Step 3.47)
38
+ - TODOS.md missing and user wants to create one (ask — see Step 5.5)
39
+ - TODOS.md disorganized and user wants to reorganize (ask — see Step 5.5)
40
+
41
+ **Never stop for:**
42
+ - Uncommitted changes (always include them)
43
+ - Version bump choice (auto-pick MICRO or PATCH — see Step 4)
44
+ - CHANGELOG content (auto-generate from diff)
45
+ - Commit message approval (auto-commit)
46
+ - Multi-file changesets (auto-split into bisectable commits)
47
+ - TODOS.md completed-item detection (auto-mark)
48
+ - Auto-fixable review findings (dead code, N+1, stale comments — fixed automatically)
49
+ - Test coverage gaps within target threshold (auto-generate and commit, or flag in PR body)
50
+
51
+ ---
52
+
53
+ ## Step 1: Pre-flight
54
+
55
+ 1. Check the current branch. If on the base branch or the repo's default branch, **abort**: "You're on the base branch. Ship from a feature branch."
56
+
57
+ 2. Run `git status` (never use `-uall`). Uncommitted changes are always included — no need to ask.
58
+
59
+ 3. Run `git diff <base>...HEAD --stat` and `git log <base>..HEAD --oneline` to understand what's being shipped.
60
+
61
+ 4. Check review readiness:
62
+
63
+ {{REVIEW_DASHBOARD}}
64
+
65
+ If the Eng Review is NOT "CLEAR":
66
+
67
+ Print: "No prior eng review found — ship will run its own pre-landing review in Step 3.5."
68
+
69
+ Check diff size: `git diff <base>...HEAD --stat | tail -1`. If the diff is >200 lines, add: "Note: This is a large diff. Consider running `/plan-eng-review` or `/autoplan` for architecture-level review before shipping."
70
+
71
+ If CEO Review is missing, mention as informational ("CEO Review not run — recommended for product changes") but do NOT block.
72
+
73
+ For Design Review: run `source <(~/.claude/skills/opengstack/bin/gstack-diff-scope <base> 2>/dev/null)`. If `SCOPE_FRONTEND=true` and no design review (plan-design-review or design-review-lite) exists in the dashboard, mention: "Design Review not run — this PR changes frontend code. The lite design check will run automatically in Step 3.5, but consider running /design-review for a full visual audit post-implementation." Still never block.
74
+
75
+ Continue to Step 1.5 — do NOT block or ask. Ship runs its own review in Step 3.5.
76
+
77
+ ---
78
+
79
+ ## Step 1.5: Distribution Pipeline Check
80
+
81
+ If the diff introduces a new standalone artifact (CLI binary, library package, tool) — not a web
82
+ service with existing deployment — verify that a distribution pipeline exists.
83
+
84
+ 1. Check if the diff adds a new `cmd/` directory, `main.go`, or `bin/` entry point:
85
+ ```bash
86
+ git diff origin/<base> --name-only | grep -E '(cmd/.*/main\.go|bin/|Cargo\.toml|setup\.py|package\.json)' | head -5
87
+ ```
88
+
89
+ 2. If new artifact detected, check for a release workflow:
90
+ ```bash
91
+ ls .github/workflows/ 2>/dev/null | grep -iE 'release|publish|dist'
92
+ grep -qE 'release|publish|deploy' .gitlab-ci.yml 2>/dev/null && echo "GITLAB_CI_RELEASE"
93
+ ```
94
+
95
+ 3. **If no release pipeline exists and a new artifact was added:** Use AskUserQuestion:
96
+ - "This PR adds a new binary/tool but there's no CI/CD pipeline to build and publish it.
97
+ Users won't be able to download the artifact after merge."
98
+ - A) Add a release workflow now (CI/CD release pipeline — GitHub Actions or GitLab CI depending on platform)
99
+ - B) Defer — add to TODOS.md
100
+ - C) Not needed — this is internal/web-only, existing deployment covers it
101
+
102
+ 4. **If release pipeline exists:** Continue silently.
103
+ 5. **If no new artifact detected:** Skip silently.
104
+
105
+ ---
106
+
107
+ ## Step 2: Merge the base branch (BEFORE tests)
108
+
109
+ Fetch and merge the base branch into the feature branch so tests run against the merged state:
110
+
111
+ ```bash
112
+ git fetch origin <base> && git merge origin/<base> --no-edit
113
+
114
+ **If there are merge conflicts:** Try to auto-resolve if they are simple (VERSION, schema.rb, CHANGELOG ordering). If conflicts are complex or ambiguous, **STOP** and show them.
115
+
116
+ **If already up to date:** Continue silently.
117
+
118
+ ---
119
+
120
+ ## Step 2.5: Test Framework Bootstrap
121
+
122
+ {{TEST_BOOTSTRAP}}
123
+
124
+ ---
125
+
126
+ ## Step 3: Run tests (on merged code)
127
+
128
+ **Do NOT run `RAILS_ENV=test bin/rails db:migrate`** — `bin/test-lane` already calls
129
+ `db:test:prepare` internally, which loads the schema into the correct lane database.
130
+ Running bare test migrations without INSTANCE hits an orphan DB and corrupts structure.sql.
131
+
132
+ Run both test suites in parallel:
133
+
134
+ ```bash
135
+ bin/test-lane 2>&1 | tee /tmp/ship_tests.txt &
136
+ npm run test 2>&1 | tee /tmp/ship_vitest.txt &
137
+ wait
138
+
139
+ After both complete, read the output files and check pass/fail.
140
+
141
+ **If any test fails:** Do NOT immediately stop. Apply the Test Failure Ownership Triage:
142
+
143
+ {{TEST_FAILURE_TRIAGE}}
144
+
145
+ **After triage:** If any in-branch failures remain unfixed, **STOP**. Do not proceed. If all failures were pre-existing and handled (fixed, TODOed, assigned, or skipped), continue to Step 3.25.
146
+
147
+ **If all pass:** Continue silently — just note the counts briefly.
148
+
149
+ ---
150
+
151
+ ## Step 3.25: Eval Suites (conditional)
152
+
153
+ Evals are mandatory when prompt-related files change. Skip this step entirely if no prompt files are in the diff.
154
+
155
+ **1. Check if the diff touches prompt-related files:**
156
+
157
+ ```bash
158
+ git diff origin/<base> --name-only
159
+
160
+ Match against these patterns (from CLAUDE.md):
161
+ - `app/services/*_prompt_builder.rb`
162
+ - `app/services/*_generation_service.rb`, `*_writer_service.rb`, `*_designer_service.rb`
163
+ - `app/services/*_evaluator.rb`, `*_scorer.rb`, `*_classifier_service.rb`, `*_analyzer.rb`
164
+ - `app/services/concerns/*voice*.rb`, `*writing*.rb`, `*prompt*.rb`, `*token*.rb`
165
+ - `app/services/chat_tools/*.rb`, `app/services/x_thread_tools/*.rb`
166
+ - `config/system_prompts/*.txt`
167
+ - `test/evals/**/*` (eval infrastructure changes affect all suites)
168
+
169
+ **If no matches:** Print "No prompt-related files changed — skipping evals." and continue to Step 3.5.
170
+
171
+ **2. Identify affected eval suites:**
172
+
173
+ Each eval runner (`test/evals/*_eval_runner.rb`) declares `PROMPT_SOURCE_FILES` listing which source files affect it. Grep these to find which suites match the changed files:
174
+
175
+ ```bash
176
+ grep -l "changed_file_basename" test/evals/*_eval_runner.rb
177
+
178
+ Map runner → test file: `post_generation_eval_runner.rb` → `post_generation_eval_test.rb`.
179
+
180
+ **Special cases:**
181
+ - Changes to `test/evals/judges/*.rb`, `test/evals/support/*.rb`, or `test/evals/fixtures/` affect ALL suites that use those judges/support files. Check imports in the eval test files to determine which.
182
+ - Changes to `config/system_prompts/*.txt` — grep eval runners for the prompt filename to find affected suites.
183
+ - If unsure which suites are affected, run ALL suites that could plausibly be impacted. Over-testing is better than missing a regression.
184
+
185
+ **3. Run affected suites at `EVAL_JUDGE_TIER=full`:**
186
+
187
+ `/ship` is a pre-merge gate, so always use full tier (Sonnet structural + Opus persona judges).
188
+
189
+ ```bash
190
+ EVAL_JUDGE_TIER=full EVAL_VERBOSE=1 bin/test-lane --eval test/evals/<suite>_eval_test.rb 2>&1 | tee /tmp/ship_evals.txt
191
+
192
+ If multiple suites need to run, run them sequentially (each needs a test lane). If the first suite fails, stop immediately — don't burn API cost on remaining suites.
193
+
194
+ **4. Check results:**
195
+
196
+ - **If any eval fails:** Show the failures, the cost dashboard, and **STOP**. Do not proceed.
197
+ - **If all pass:** Note pass counts and cost. Continue to Step 3.5.
198
+
199
+ **5. Save eval output** — include eval results and cost dashboard in the PR body (Step 8).
200
+
201
+ **Tier reference (for context — /ship always uses `full`):**
202
+ | Tier | When | Speed (cached) | Cost |
203
+ |------|------|----------------|------|
204
+ | `fast` (Haiku) | Dev iteration, smoke tests | ~5s (14x faster) | ~$0.07/run |
205
+ | `standard` (Sonnet) | Default dev, `bin/test-lane --eval` | ~17s (4x faster) | ~$0.37/run |
206
+ | `full` (Opus persona) | **`/ship` and pre-merge** | ~72s (baseline) | ~$1.27/run |
207
+
208
+ ---
209
+
210
+ ## Step 3.4: Test Coverage Audit
211
+
212
+ {{TEST_COVERAGE_AUDIT_SHIP}}
213
+
214
+ ---
215
+
216
+ ## Step 3.45: Plan Completion Audit
217
+
218
+ {{PLAN_COMPLETION_AUDIT_SHIP}}
219
+
220
+ ---
221
+
222
+ {{PLAN_VERIFICATION_EXEC}}
223
+
224
+ ---
225
+
226
+ ## Step 3.5: Pre-Landing Review
227
+
228
+ Review the diff for structural issues that tests don't catch.
229
+
230
+ 1. Read `.claude/skills/review/checklist.md`. If the file cannot be read, **STOP** and report the error.
231
+
232
+ 2. Run `git diff origin/<base>` to get the full diff (scoped to feature changes against the freshly-fetched base branch).
233
+
234
+ 3. Apply the review checklist in two passes:
235
+ - **Pass 1 (CRITICAL):** SQL & Data Safety, LLM Output Trust Boundary
236
+ - **Pass 2 (INFORMATIONAL):** All remaining categories
237
+
238
+ {{DESIGN_REVIEW_LITE}}
239
+
240
+ Include any design findings alongside the code review findings. They follow the same Fix-First flow below.
241
+
242
+ 4. **Classify each finding as AUTO-FIX or ASK** per the Fix-First Heuristic in
243
+ checklist.md. Critical findings lean toward ASK; informational lean toward AUTO-FIX.
244
+
245
+ 5. **Auto-fix all AUTO-FIX items.** Apply each fix. Output one line per fix:
246
+ `[AUTO-FIXED] [file:line] Problem → what you did`
247
+
248
+ 6. **If ASK items remain,** present them in ONE AskUserQuestion:
249
+ - List each with number, severity, problem, recommended fix
250
+ - Per-item options: A) Fix B) Skip
251
+ - Overall RECOMMENDATION
252
+ - If 3 or fewer ASK items, you may use individual AskUserQuestion calls instead
253
+
254
+ 7. **After all fixes (auto + user-approved):**
255
+ - If ANY fixes were applied: commit fixed files by name (`git add <fixed-files> && git commit -m "fix: pre-landing review fixes"`), then **STOP** and tell the user to run `/ship` again to re-test.
256
+ - If no fixes applied (all ASK items skipped, or no issues found): continue to Step 4.
257
+
258
+ 8. Output summary: `Pre-Landing Review: N issues — M auto-fixed, K asked (J fixed, L skipped)`
259
+
260
+ If no issues found: `Pre-Landing Review: No issues found.`
261
+
262
+ 9. Persist the review result to the review log:
263
+ ```bash
264
+ ~/.claude/skills/opengstack/bin/gstack-review-log '{"skill":"review","timestamp":"TIMESTAMP","status":"STATUS","issues_found":N,"critical":N,"informational":N,"commit":"'"$(git rev-parse --short HEAD)"'","via":"ship"}'
265
+
266
+ Substitute TIMESTAMP (ISO 8601), STATUS ("clean" if no issues, "issues_found" otherwise),
267
+ and N values from the summary counts above. The `via:"ship"` distinguishes from standalone `/review` runs.
268
+
269
+ Save the review output — it goes into the PR body in Step 8.
270
+
271
+ ---
272
+
273
+ ## Step 3.75: Address Greptile review comments (if PR exists)
274
+
275
+ Read `.claude/skills/review/greptile-triage.md` and follow the fetch, filter, classify, and **escalation detection** steps.
276
+
277
+ **If no PR exists, `gh` fails, API returns an error, or there are zero Greptile comments:** Skip this step silently. Continue to Step 4.
278
+
279
+ **If Greptile comments are found:**
280
+
281
+ Include a Greptile summary in your output: `+ N Greptile comments (X valid, Y fixed, Z FP)`
282
+
283
+ Before replying to any comment, run the **Escalation Detection** algorithm from greptile-triage.md to determine whether to use Tier 1 (friendly) or Tier 2 (firm) reply templates.
284
+
285
+ For each classified comment:
286
+
287
+ **VALID & ACTIONABLE:** Use AskUserQuestion with:
288
+ - The comment (file:line or [top-level] + body summary + permalink URL)
289
+ - `RECOMMENDATION: Choose A because [one-line reason]`
290
+ - Options: A) Fix now, B) Acknowledge and ship anyway, C) It's a false positive
291
+ - If user chooses A: apply the fix, commit the fixed files (`git add <fixed-files> && git commit -m "fix: address Greptile review — <brief description>"`), reply using the **Fix reply template** from greptile-triage.md (include inline diff + explanation), and save to both per-project and global greptile-history (type: fix).
292
+ - If user chooses C: reply using the **False Positive reply template** from greptile-triage.md (include evidence + suggested re-rank), save to both per-project and global greptile-history (type: fp).
293
+
294
+ **VALID BUT ALREADY FIXED:** Reply using the **Already Fixed reply template** from greptile-triage.md — no AskUserQuestion needed:
295
+ - Include what was done and the fixing commit SHA
296
+ - Save to both per-project and global greptile-history (type: already-fixed)
297
+
298
+ **FALSE POSITIVE:** Use AskUserQuestion:
299
+ - Show the comment and why you think it's wrong (file:line or [top-level] + body summary + permalink URL)
300
+ - Options:
301
+ - A) Reply to Greptile explaining the false positive (recommended if clearly wrong)
302
+ - B) Fix it anyway (if trivial)
303
+ - C) Ignore silently
304
+ - If user chooses A: reply using the **False Positive reply template** from greptile-triage.md (include evidence + suggested re-rank), save to both per-project and global greptile-history (type: fp)
305
+
306
+ **SUPPRESSED:** Skip silently — these are known false positives from previous triage.
307
+
308
+ **After all comments are resolved:** If any fixes were applied, the tests from Step 3 are now stale. **Re-run tests** (Step 3) before continuing to Step 4. If no fixes were applied, continue to Step 4.
309
+
310
+ ---
311
+
312
+ {{ADVERSARIAL_STEP}}
313
+
314
+ ## Step 4: Version bump (auto-decide)
315
+
316
+ 1. Read the current `VERSION` file (4-digit format: `MAJOR.MINOR.PATCH.MICRO`)
317
+
318
+ 2. **Auto-decide the bump level based on the diff:**
319
+ - Count lines changed (`git diff origin/<base>...HEAD --stat | tail -1`)
320
+ - **MICRO** (4th digit): < 50 lines changed, trivial tweaks, typos, config
321
+ - **PATCH** (3rd digit): 50+ lines changed, bug fixes, small-medium features
322
+ - **MINOR** (2nd digit): **ASK the user** — only for major features or significant architectural changes
323
+ - **MAJOR** (1st digit): **ASK the user** — only for milestones or breaking changes
324
+
325
+ 3. Compute the new version:
326
+ - Bumping a digit resets all digits to its right to 0
327
+ - Example: `0.19.1.0` + PATCH → `0.19.2.0`
328
+
329
+ 4. Write the new version to the `VERSION` file.
330
+
331
+ ---
332
+
333
+ ## Step 5: CHANGELOG (auto-generate)
334
+
335
+ 1. Read `CHANGELOG.md` header to know the format.
336
+
337
+ 2. **First, enumerate every commit on the branch:**
338
+ ```bash
339
+ git log <base>..HEAD --oneline
340
+ ```
341
+ Copy the full list. Count the commits. You will use this as a checklist.
342
+
343
+ 3. **Read the full diff** to understand what each commit actually changed:
344
+ ```bash
345
+ git diff <base>...HEAD
346
+ ```
347
+
348
+ 4. **Group commits by theme** before writing anything. Common themes:
349
+ - New features / capabilities
350
+ - Performance improvements
351
+ - Bug fixes
352
+ - Dead code removal / cleanup
353
+ - Infrastructure / tooling / tests
354
+ - Refactoring
355
+
356
+ 5. **Write the CHANGELOG entry** covering ALL groups:
357
+ - If existing CHANGELOG entries on the branch already cover some commits, replace them with one unified entry for the new version
358
+ - Categorize changes into applicable sections:
359
+ - `### Added` — new features
360
+ - `### Changed` — changes to existing functionality
361
+ - `### Fixed` — bug fixes
362
+ - `### Removed` — removed features
363
+ - Write concise, descriptive bullet points
364
+ - Insert after the file header (line 5), dated today
365
+ - Format: `## [X.Y.Z.W] - YYYY-MM-DD`
366
+
367
+ 6. **Cross-check:** Compare your CHANGELOG entry against the commit list from step 2.
368
+ Every commit must map to at least one bullet point. If any commit is unrepresented,
369
+ add it now. If the branch has N commits spanning K themes, the CHANGELOG must
370
+ reflect all K themes.
371
+
372
+ **Do NOT ask the user to describe changes.** Infer from the diff and commit history.
373
+
374
+ ---
375
+
376
+ ## Step 5.5: TODOS.md (auto-update)
377
+
378
+ Cross-reference the project's TODOS.md against the changes being shipped. Mark completed items automatically; prompt only if the file is missing or disorganized.
379
+
380
+ Read `.claude/skills/review/TODOS-format.md` for the canonical format reference.
381
+
382
+ **1. Check if TODOS.md exists** in the repository root.
383
+
384
+ **If TODOS.md does not exist:** Use AskUserQuestion:
385
+ - Message: "OpenGStack recommends maintaining a TODOS.md organized by skill/component, then priority (P0 at top through P4, then Completed at bottom). See TODOS-format.md for the full format. Would you like to create one?"
386
+ - Options: A) Create it now, B) Skip for now
387
+ - If A: Create `TODOS.md` with a skeleton (# TODOS heading + ## Completed section). Continue to step 3.
388
+ - If B: Skip the rest of Step 5.5. Continue to Step 6.
389
+
390
+ **2. Check structure and organization:**
391
+
392
+ Read TODOS.md and verify it follows the recommended structure:
393
+ - Items grouped under `## <Skill/Component>` headings
394
+ - Each item has `**Priority:**` field with P0-P4 value
395
+ - A `## Completed` section at the bottom
396
+
397
+ **If disorganized** (missing priority fields, no component groupings, no Completed section): Use AskUserQuestion:
398
+ - Message: "TODOS.md doesn't follow the recommended structure (skill/component groupings, P0-P4 priority, Completed section). Would you like to reorganize it?"
399
+ - Options: A) Reorganize now (recommended), B) Leave as-is
400
+ - If A: Reorganize in-place following TODOS-format.md. Preserve all content — only restructure, never delete items.
401
+ - If B: Continue to step 3 without restructuring.
402
+
403
+ **3. Detect completed TODOs:**
404
+
405
+ This step is fully automatic — no user interaction.
406
+
407
+ Use the diff and commit history already gathered in earlier steps:
408
+ - `git diff <base>...HEAD` (full diff against the base branch)
409
+ - `git log <base>..HEAD --oneline` (all commits being shipped)
410
+
411
+ For each TODO item, check if the changes in this PR complete it by:
412
+ - Matching commit messages against the TODO title and description
413
+ - Checking if files referenced in the TODO appear in the diff
414
+ - Checking if the TODO's described work matches the functional changes
415
+
416
+ **Be conservative:** Only mark a TODO as completed if there is clear evidence in the diff. If uncertain, leave it alone.
417
+
418
+ **4. Move completed items** to the `## Completed` section at the bottom. Append: `**Completed:** vX.Y.Z (YYYY-MM-DD)`
419
+
420
+ **5. Output summary:**
421
+ - `TODOS.md: N items marked complete (item1, item2, ...). M items remaining.`
422
+ - Or: `TODOS.md: No completed items detected. M items remaining.`
423
+ - Or: `TODOS.md: Created.` / `TODOS.md: Reorganized.`
424
+
425
+ **6. Defensive:** If TODOS.md cannot be written (permission error, disk full), warn the user and continue. Never stop the ship workflow for a TODOS failure.
426
+
427
+ Save this summary — it goes into the PR body in Step 8.
428
+
429
+ ---
430
+
431
+ ## Step 6: Commit (bisectable chunks)
432
+
433
+ **Goal:** Create small, logical commits that work well with `git bisect` and help LLMs understand what changed.
434
+
435
+ 1. Analyze the diff and group changes into logical commits. Each commit should represent **one coherent change** — not one file, but one logical unit.
436
+
437
+ 2. **Commit ordering** (earlier commits first):
438
+ - **Infrastructure:** migrations, config changes, route additions
439
+ - **Models & services:** new models, services, concerns (with their tests)
440
+ - **Controllers & views:** controllers, views, JS/React components (with their tests)
441
+ - **VERSION + CHANGELOG + TODOS.md:** always in the final commit
442
+
443
+ 3. **Rules for splitting:**
444
+ - A model and its test file go in the same commit
445
+ - A service and its test file go in the same commit
446
+ - A controller, its views, and its test go in the same commit
447
+ - Migrations are their own commit (or grouped with the model they support)
448
+ - Config/route changes can group with the feature they enable
449
+ - If the total diff is small (< 50 lines across < 4 files), a single commit is fine
450
+
451
+ 4. **Each commit must be independently valid** — no broken imports, no references to code that doesn't exist yet. Order commits so dependencies come first.
452
+
453
+ 5. Compose each commit message:
454
+ - First line: `<type>: <summary>` (type = feat/fix/chore/refactor/docs)
455
+ - Body: brief description of what this commit contains
456
+ - Only the **final commit** (VERSION + CHANGELOG) gets the version tag and co-author trailer:
457
+
458
+ ```bash
459
+ git commit -m "$(cat <<'EOF'
460
+ chore: bump version and changelog (vX.Y.Z.W)
461
+
462
+ {{CO_AUTHOR_TRAILER}}
463
+ EOF
464
+ )"
465
+
466
+ ---
467
+
468
+ ## Step 6.5: Verification Gate
469
+
470
+ **IRON LAW: NO COMPLETION CLAIMS WITHOUT FRESH VERIFICATION EVIDENCE.**
471
+
472
+ Before pushing, re-verify if code changed during Steps 4-6:
473
+
474
+ 1. **Test verification:** If ANY code changed after Step 3's test run (fixes from review findings, CHANGELOG edits don't count), re-run the test suite. Paste fresh output. Stale output from Step 3 is NOT acceptable.
475
+
476
+ 2. **Build verification:** If the project has a build step, run it. Paste output.
477
+
478
+ 3. **Rationalization prevention:**
479
+ - "Should work now" → RUN IT.
480
+ - "I'm confident" → Confidence is not evidence.
481
+ - "I already tested earlier" → Code changed since then. Test again.
482
+ - "It's a trivial change" → Trivial changes break production.
483
+
484
+ **If tests fail here:** STOP. Do not push. Fix the issue and return to Step 3.
485
+
486
+ Claiming work is complete without verification is dishonesty, not efficiency.
487
+
488
+ ---
489
+
490
+ ## Step 7: Push
491
+
492
+ Push to the remote with upstream tracking:
493
+
494
+ ```bash
495
+ git push -u origin <branch-name>
496
+
497
+ ---
498
+
499
+ ## Step 8: Create PR/MR
500
+
501
+ Create a pull request (GitHub) or merge request (GitLab) using the platform detected in Step 0.
502
+
503
+ The PR/MR body should contain these sections:
504
+
505
+
506
+ ## Summary
507
+ <Summarize ALL changes being shipped. Run `git log <base>..HEAD --oneline` to enumerate
508
+ every commit. Exclude the VERSION/CHANGELOG metadata commit (that's this PR's bookkeeping,
509
+ not a substantive change). Group the remaining commits into logical sections (e.g.,
510
+ "**Performance**", "**Dead Code Removal**", "**Infrastructure**"). Every substantive commit
511
+ must appear in at least one section. If a commit's work isn't reflected in the summary,
512
+ you missed it.>
513
+
514
+ ## Test Coverage
515
+ <coverage diagram from Step 3.4, or "All new code paths have test coverage.">
516
+ <If Step 3.4 ran: "Tests: {before} → {after} (+{delta} new)">
517
+
518
+ ## Pre-Landing Review
519
+ <findings from Step 3.5 code review, or "No issues found.">
520
+
521
+ ## Design Review
522
+ <If design review ran: "Design Review (lite): N findings — M auto-fixed, K skipped. AI Slop: clean/N issues.">
523
+ <If no frontend files changed: "No frontend files changed — design review skipped.">
524
+
525
+ ## Eval Results
526
+ <If evals ran: suite names, pass/fail counts, cost dashboard summary. If skipped: "No prompt-related files changed — evals skipped.">
527
+
528
+ ## Greptile Review
529
+ <If Greptile comments were found: bullet list with [FIXED] / [FALSE POSITIVE] / [ALREADY FIXED] tag + one-line summary per comment>
530
+ <If no Greptile comments found: "No Greptile comments.">
531
+ <If no PR existed during Step 3.75: omit this section entirely>
532
+
533
+ ## Plan Completion
534
+ <If plan file found: completion checklist summary from Step 3.45>
535
+ <If no plan file: "No plan file detected.">
536
+ <If plan items deferred: list deferred items>
537
+
538
+ ## Verification Results
539
+ <If verification ran: summary from Step 3.47 (N PASS, M FAIL, K SKIPPED)>
540
+ <If skipped: reason (no plan, no server, no verification section)>
541
+ <If not applicable: omit this section>
542
+
543
+ ## TODOS
544
+ <If items marked complete: bullet list of completed items with version>
545
+ <If no items completed: "No TODO items completed in this PR.">
546
+ <If TODOS.md created or reorganized: note that>
547
+ <If TODOS.md doesn't exist and user skipped: omit this section>
548
+
549
+ ## Test plan
550
+ - [x] All Rails tests pass (N runs, 0 failures)
551
+ - [x] All Vitest tests pass (N tests)
552
+
553
+ 🤖 Generated with [Claude Code](https://claude.com/claude-code)
554
+
555
+ **If GitHub:**
556
+
557
+ ```bash
558
+ gh pr create --base <base> --title "<type>: <summary>" --body "$(cat <<'EOF'
559
+ <PR body from above>
560
+ EOF
561
+ )"
562
+
563
+ **If GitLab:**
564
+
565
+ ```bash
566
+ glab mr create -b <base> -t "<type>: <summary>" -d "$(cat <<'EOF'
567
+ <MR body from above>
568
+ EOF
569
+ )"
570
+
571
+ **If neither CLI is available:**
572
+ Print the branch name, remote URL, and instruct the user to create the PR/MR manually via the web UI. Do not stop — the code is pushed and ready.
573
+
574
+ **Output the PR/MR URL** — then proceed to Step 8.5.
575
+
576
+ ---
577
+
578
+ ## Step 8.5: Auto-invoke /document-release
579
+
580
+ After the PR is created, automatically sync project documentation. Read the
581
+ `document-release/SKILL.md` skill file (adjacent to this skill's directory) and
582
+ execute its full workflow:
583
+
584
+ 1. Read the `/document-release` skill: `cat ${CLAUDE_SKILL_DIR}/../document-release/SKILL.md`
585
+ 2. Follow its instructions — it reads all .md files in the project, cross-references
586
+ the diff, and updates anything that drifted (README, ARCHITECTURE, CONTRIBUTING,
587
+ CLAUDE.md, TODOS, etc.)
588
+ 3. If any docs were updated, commit the changes and push to the same branch:
589
+ ```bash
590
+ git add -A && git commit -m "docs: sync documentation with shipped changes" && git push
591
+ ```
592
+ 4. If no docs needed updating, say "Documentation is current — no updates needed."
593
+
594
+ This step is automatic. Do not ask the user for confirmation. The goal is zero-friction
595
+ doc updates — the user runs `/ship` and documentation stays current without a separate command.
596
+
597
+ ---
598
+
599
+ ## Step 8.75: Persist ship metrics
600
+
601
+ Log coverage and plan completion data so `/retro` can track trends:
602
+
603
+ ```bash
604
+ eval "$(~/.claude/skills/opengstack/bin/gstack-slug 2>/dev/null)" && mkdir -p ~/.gstack/projects/$SLUG
605
+
606
+ Append to `~/.gstack/projects/$SLUG/$BRANCH-reviews.jsonl`:
607
+
608
+ ```bash
609
+ echo '{"skill":"ship","timestamp":"'"$(date -u +%Y-%m-%dT%H:%M:%SZ)"'","coverage_pct":COVERAGE_PCT,"plan_items_total":PLAN_TOTAL,"plan_items_done":PLAN_DONE,"verification_result":"VERIFY_RESULT","version":"VERSION","branch":"BRANCH"}' >> ~/.gstack/projects/$SLUG/$BRANCH-reviews.jsonl
610
+
611
+ Substitute from earlier steps:
612
+ - **COVERAGE_PCT**: coverage percentage from Step 3.4 diagram (integer, or -1 if undetermined)
613
+ - **PLAN_TOTAL**: total plan items extracted in Step 3.45 (0 if no plan file)
614
+ - **PLAN_DONE**: count of DONE + CHANGED items from Step 3.45 (0 if no plan file)
615
+ - **VERIFY_RESULT**: "pass", "fail", or "skipped" from Step 3.47
616
+ - **VERSION**: from the VERSION file
617
+ - **BRANCH**: current branch name
618
+
619
+ This step is automatic — never skip it, never ask for confirmation.
620
+
621
+ ---
622
+
623
+ ## Important Rules
624
+
625
+ - **Never skip tests.** If tests fail, stop.
626
+ - **Never skip the pre-landing review.** If checklist.md is unreadable, stop.
627
+ - **Never force push.** Use regular `git push` only.
628
+ - **Never ask for trivial confirmations** (e.g., "ready to push?", "create PR?"). DO stop for: version bumps (MINOR/MAJOR), pre-landing review findings (ASK items), and Codex structured review [P1] findings (large diffs only).
629
+ - **Always use the 4-digit version format** from the VERSION file.
630
+ - **Date format in CHANGELOG:** `YYYY-MM-DD`
631
+ - **Split commits for bisectability** — each commit = one logical change.
632
+ - **TODOS.md completion detection must be conservative.** Only mark items as completed when the diff clearly shows the work is done.
633
+ - **Use Greptile reply templates from greptile-triage.md.** Every reply includes evidence (inline diff, code references, re-rank suggestion). Never post vague replies.
634
+ - **Never push without fresh verification evidence.** If code changed after Step 3 tests, re-run before pushing.
635
+ - **Step 3.4 generates coverage tests.** They must pass before committing. Never commit failing tests.
636
+ - **The goal is: user says `/ship`, next thing they see is the review + PR URL + auto-synced docs.**
@@ -0,0 +1,37 @@
1
+ ---
2
+ name: unfreeze
3
+ version: 0.1.0
4
+ description: |
5
+ Clear the freeze boundary set by /freeze, allowing edits to all directories
6
+ again. Use when you want to widen edit scope without ending the session.
7
+ Use when asked to "unfreeze", "unlock edits", "remove freeze", or
8
+ "allow all edits".
9
+ allowed-tools:
10
+ - Bash
11
+ - Read
12
+ ---
13
+ <!-- AUTO-GENERATED from SKILL.md.tmpl — do not edit directly -->
14
+ <!-- Regenerate: bun run gen:skill-docs -->
15
+
16
+ # /unfreeze — Clear Freeze Boundary
17
+
18
+ Remove the edit restriction set by `/freeze`, allowing edits to all directories.
19
+
20
+ ```bash
21
+ mkdir -p ~/.gstack/analytics
22
+ echo '{"skill":"unfreeze","ts":"'$(date -u +%Y-%m-%dT%H:%M:%SZ)'","repo":"'$(basename "$(git rev-parse --show-toplevel 2>/dev/null)" 2>/dev/null || echo "unknown")'"}' >> ~/.gstack/analytics/skill-usage.jsonl 2>/dev/null || true
23
+
24
+ ## Clear the boundary
25
+
26
+ ```bash
27
+ STATE_DIR="${CLAUDE_PLUGIN_DATA:-$HOME/.gstack}"
28
+ if [ -f "$STATE_DIR/freeze-dir.txt" ]; then
29
+ PREV=$(cat "$STATE_DIR/freeze-dir.txt")
30
+ rm -f "$STATE_DIR/freeze-dir.txt"
31
+ echo "Freeze boundary cleared (was: $PREV). Edits are now allowed everywhere."
32
+ else
33
+ echo "No freeze boundary was set."
34
+ fi
35
+
36
+ session — they will just allow everything since no state file exists. To re-freeze,
37
+ run `/freeze` again.