Skip to content

feat(ship): skip version-bump/CHANGELOG/title-rewrite when the repo has no VERSION file#2343

Open
merit-blake wants to merge 1 commit into
garrytan:mainfrom
merit-blake:ship-skip-no-version-file
Open

feat(ship): skip version-bump/CHANGELOG/title-rewrite when the repo has no VERSION file#2343
merit-blake wants to merge 1 commit into
garrytan:mainfrom
merit-blake:ship-skip-no-version-file

Conversation

@merit-blake

Copy link
Copy Markdown

feat(ship): skip version-bump/CHANGELOG/title-rewrite when the repo has no VERSION file

Repos that stamp versions at release/queue time (merge-queue driven repos,
release-please/tag-based flows) have no VERSION file, but /ship today
manufactures one: gstack-version-bump treats a missing file as 0.0.0.0,
classifies FRESH, and write creates VERSION at the bumped slot - then
writes a CHANGELOG release heading and rewrites the PR title to vX.Y.Z.W.
On a queue-managed repo every such PR textually collides with every other
(we hit three pairs of open PRs claiming identical versions in one repo
before tracing it here).

The convention was already keyed off the VERSION file's presence; this
makes the absence a first-class state instead of a 0.0.0.0 default:

  • gstack-version-bump classify: new NO_VERSION_FILE state when the
    resolved version file does not exist (never invents 0.0.0.0, never
    creates the file; also covers a branch that deletes VERSION to retire
    the convention). write/repair are unchanged.
  • ship Step 12: NO_VERSION_FILE dispatch arm - skip Steps 12-13 and the
    PR/MR title version invariant; plain : titles; never
    create a VERSION file. Idempotency note updated for re-runs.
  • ship Step 13 (CHANGELOG): explicit skip under NO_VERSION_FILE.
  • ship title invariant: now conditional on Step 12 having produced a
    version.
  • land-and-deploy Step 3.4: VERSION drift detection prints n/a and skips
    when neither the head nor the base has a VERSION file.
  • Tests: NO_VERSION_FILE for a never-versioned repo (asserts classify
    stays a pure reader and creates nothing) and for a branch that deleted
    VERSION while base still has it. bun test on gstack-version-bump,
    ship-version-sync, gstack-next-version: 59 pass / 0 fail.

Generated SKILL.md files regenerated with bun run gen:skill-docs.

…as no VERSION file

Repos that stamp versions at release/queue time (merge-queue driven repos,
release-please/tag-based flows) have no VERSION file, but /ship today
manufactures one: gstack-version-bump treats a missing file as 0.0.0.0,
classifies FRESH, and `write` creates VERSION at the bumped slot - then
writes a CHANGELOG release heading and rewrites the PR title to vX.Y.Z.W.
On a queue-managed repo every such PR textually collides with every other
(we hit three pairs of open PRs claiming identical versions in one repo
before tracing it here).

The convention was already keyed off the VERSION file's presence; this
makes the absence a first-class state instead of a 0.0.0.0 default:

- gstack-version-bump classify: new NO_VERSION_FILE state when the
  resolved version file does not exist (never invents 0.0.0.0, never
  creates the file; also covers a branch that deletes VERSION to retire
  the convention). write/repair are unchanged.
- ship Step 12: NO_VERSION_FILE dispatch arm - skip Steps 12-13 and the
  PR/MR title version invariant; plain <type>: <summary> titles; never
  create a VERSION file. Idempotency note updated for re-runs.
- ship Step 13 (CHANGELOG): explicit skip under NO_VERSION_FILE.
- ship title invariant: now conditional on Step 12 having produced a
  version.
- land-and-deploy Step 3.4: VERSION drift detection prints n/a and skips
  when neither the head nor the base has a VERSION file.
- Tests: NO_VERSION_FILE for a never-versioned repo (asserts classify
  stays a pure reader and creates nothing) and for a branch that deleted
  VERSION while base still has it. bun test on gstack-version-bump,
  ship-version-sync, gstack-next-version: 59 pass / 0 fail.

Generated SKILL.md files regenerated with bun run gen:skill-docs.
@trunk-io

trunk-io Bot commented Jul 25, 2026

Copy link
Copy Markdown

Merging to main in this repository is managed by Trunk.

  • To merge this pull request, check the box to the left or comment /trunk merge below.

After your PR is submitted to the merge queue, this comment will be automatically updated with its status. If the PR fails, failure details will also be posted here

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