Skip to content

fix(release): cut prerelease tags from dev - #8

Open
singlerider wants to merge 1 commit into
mainfrom
fix/release-rc-from-dev
Open

singlerider wants to merge 1 commit into
mainfrom
fix/release-rc-from-dev

Conversation

@singlerider

Copy link
Copy Markdown
Contributor

What

release.sh cuts -rc.N tags from dev and release tags from the default branch.

  • A tag matching -rc.N requires a clean dev checkout equal to <remote>/dev.
  • Every other tag still requires the default branch, equal to its remote.

Why

The script required every tag to come from the default branch. In repos whose default branch is stable (bbot), the documented prerelease path, release.sh vX.Y.Z-rc.N from dev, died with "not trunk 'stable'". Raised by en0f and liquidsec on blacklanternsecurity/bbot#3355. With publishing tag-only, an rc tag from dev is the only thing that moves the :dev image, so this path has to work.

Validation

  • Scratch repo, default branch stable: rc tag on dev reaches the confirm prompt. rc on stable, a release on dev, and a detached HEAD are refused. A release on stable reaches the prompt.
  • uvx --from shellcheck-py shellcheck scripts/release.sh: clean.
  • pytest: 16 passed.

After merge, bbot#3355 repins to the merge commit.

Refs blacklanternsecurity/bbot-enterprise#139
Refs blacklanternsecurity/bbot#3355

release.sh required every tag to be cut from the default branch. In
repositories whose default branch is stable, the documented prerelease
path (vX.Y.Z-rc.N from dev) died with "not trunk 'stable'".

Tags matching -rc.N now require a clean dev checkout equal to the remote
dev. Release tags still require the default branch. Verified in a
scratch repo: rc on dev reaches the confirm prompt, rc on stable and a
release on dev or a detached HEAD are refused.

Refs blacklanternsecurity/bbot-enterprise#139
@singlerider
singlerider requested a review from en0f October 8, 2026 19:26
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.

2 participants