Skip to content

feat: ship run log persistence for /retro velocity tracking#324

Open
jithinraj wants to merge 1 commit intogarrytan:mainfrom
jithinraj:feat/ship-log
Open

feat: ship run log persistence for /retro velocity tracking#324
jithinraj wants to merge 1 commit intogarrytan:mainfrom
jithinraj:feat/ship-log

Conversation

@jithinraj
Copy link
Copy Markdown

@jithinraj jithinraj commented Mar 22, 2026

Summary

Structured ship run logging for /retro velocity tracking. Addresses P2 TODO: "Ship log — persistent record of /ship runs" (TODOS.md line 268).

What ships:

  • bin/gstack-ship-log — JSONL read/write helper with --window date filtering (macOS + Linux)
  • ship/SKILL.md.tmpl Step 8.25 — appends 13-field entry after PR creation (version, branch, PR URL, review findings, Greptile stats, coverage delta)
  • retro/SKILL.md.tmpl — full consumption: command 14 reads log, Step 2 aggregates Ship Velocity metric, Steps 13-14 include velocity in saved JSON and narrative
  • test/ship-log.test.ts — 9 unit tests (syntax, append, read, window filter, help, edge cases)
  • Touchfile entries for E2E coverage (ship-log: periodic)
  • Fixes pre-existing duplicate command Feedback #12 in retro template

Design choices:

  • JSONL format (matches gstack-telemetry-log, gstack-review-log patterns) — not JSON array
  • Dedicated bin helper with read --window — retro gets date-filtered data without parsing raw files
  • set -uo pipefail (no -e), all writes guarded with 2>/dev/null || true — ship workflow never fails for a log write
  • Works across all 8 hosts (path rewriting verified: Claude, Codex, Factory, Kiro, OpenCode, Slate, Cursor, OpenClaw)

Test Coverage

9 new unit tests in test/ship-log.test.ts. All existing tests pass.

Pre-Landing Review

No issues found.

Test plan

  • bash -n bin/gstack-ship-log passes syntax check
  • bun test test/ship-log.test.ts — 9 pass, 0 fail
  • bun test — all suites pass (1/2 pre-existing on main)
  • bun run skill:check — 36/36 skills healthy
  • bun run gen:skill-docs --host all --dry-run — all 8 hosts FRESH
  • Path rewriting verified: $GSTACK_ROOT/bin/gstack-ship-log in Codex/Factory, host-specific paths in Kiro/OpenCode/Slate/Cursor/OpenClaw

@jithinraj jithinraj force-pushed the feat/ship-log branch 3 times, most recently from 61db776 to e6a47ff Compare March 25, 2026 10:58
Adds structured JSONL logging to /ship and consumption in /retro,
enabling shipping velocity metrics across retrospectives.

- bin/gstack-ship-log: read/write helper with --window date filtering
- ship Step 8.25: appends entry after PR creation (version, branch,
  PR URL, review findings, Greptile stats, coverage delta)
- retro Step 1 command 14: reads ship log for velocity aggregation
- retro Step 2: Ship Velocity metric row
- retro Steps 13-14: ship_velocity in saved JSON and narrative

Follows existing JSONL patterns (gstack-review-log, gstack-telemetry-log).
Graceful fallback: log failures never block /ship workflow.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant