Skip to content

fix(release): always publish stable to VS Code Marketplace#125

Merged
arnaudlh merged 1 commit into
mainfrom
fix/release-drop-odd-minor-prerelease
May 28, 2026
Merged

fix(release): always publish stable to VS Code Marketplace#125
arnaudlh merged 1 commit into
mainfrom
fix/release-drop-odd-minor-prerelease

Conversation

@arnaudlh
Copy link
Copy Markdown
Member

Why

Run https://github.com/Azure/git-ape/actions/runs/26485522294 failed at the Publish to VS Code Marketplace step with:

Cannot use '--pre-release' flag with a package that was not packaged as pre-release. Please package it using the '--pre-release' flag and publish again.

For v0.1.0, the workflow computed MINOR=1 → odd → vsce publish --pre-release, but the VSIX is always packaged without --pre-release, so vsce rejected it.

The odd-minor / even-minor channel scheme is an opt-in convention used by some Microsoft extensions (Python, etc.), not a Marketplace requirement.

What

  • Removed the odd/even minor branching in the marketplace publish step.
  • Always publish as a stable Marketplace release.
  • Kept the existing guard: semver pre-release suffixes (e.g. 0.1.0-rc.1) continue to skip marketplace publish entirely.

Follow-up

v0.1.0 cannot be re-published with the same version. Cut a new tag (e.g. v0.1.1) after merge to verify the publish path.

Drop the odd-minor / even-minor convention from the marketplace publish
step. It was triggering 'Cannot use --pre-release flag with a package
that was not packaged as pre-release' on v0.1.0 because the VSIX is
always packaged without --pre-release.

The odd/even minor scheme is an opt-in convention used by some
Microsoft extensions, not a marketplace requirement. We publish every
release as a stable marketplace release; semver pre-release suffixes
(e.g. 0.1.0-rc.1) continue to skip marketplace publish entirely.
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR fixes the VS Code Marketplace publish failure in the release workflow by removing the odd/even-minor prerelease branching and always publishing Marketplace releases as stable (while still skipping Marketplace publish for semver prerelease-suffix versions like 0.1.0-rc.1).

Changes:

  • Remove minor-parity logic that conditionally added vsce publish --pre-release.
  • Always run vsce publish as a stable (Release channel) publish for non-prerelease semver versions.
  • Keep the existing guard to skip Marketplace publish when the version includes a semver prerelease suffix.
Show a summary per file
File Description
.github/workflows/git-ape-release.yml Simplifies Marketplace publishing to always publish stable and avoids --pre-release mismatch with a stable-packaged VSIX.

Copilot's findings

  • Files reviewed: 1/1 changed files
  • Comments generated: 0

@sendtoshailesh
Copy link
Copy Markdown
Contributor

Review summary

This PR correctly fixes the v0.1.0 marketplace publish failure by removing the odd/even minor version branching logic. The workflow now always publishes to the stable Marketplace channel, matching how the VSIX is actually packaged (without --pre-release).

Correctness

  • ✅ Root cause diagnosis is accurate: v0.1.0 triggered MINOR=1 → odd → vsce publish --pre-release, but the VSIX was packaged without --pre-release at line 259, causing the flag mismatch error
  • ✅ Fix correctly removes the MINOR calculation and dynamic $FLAG logic (lines 320-332 deleted)
  • ✅ Semver pre-release suffix check (lines 314-318) correctly preserved — versions like 0.1.0-rc.1 will still skip marketplace publish entirely
  • ✅ Updated comment accurately explains the odd/even scheme is opt-in, not a Marketplace requirement
  • ✅ CI checks all passing (Analyze, Markdown Lint, Structural Validation, actionlint, CLA)
  • ✅ Verified the vsce package step at line 259 has never used --pre-release, confirming the mismatch was in the publish step only

Minor nits (non-blocking)

  1. website/docs/workflows/git-ape-release.md lines 353-354 still reference the old odd/even scheme — though this file is auto-generated (header says "DO NOT EDIT"), so it will regenerate on next docs build. No action needed if docs rebuild on merge.
  2. Follow-up note: As the PR body mentions, v0.1.0 cannot be republished with the same version. A new tag (e.g., v0.1.1) will be needed after merge to verify the fix. Consider updating CHANGELOG.md to document this fix.

LGTM — This fix directly addresses the failure and simplifies the workflow by removing the opt-in odd/even convention that wasn't being followed in the packaging step.

@arnaudlh arnaudlh merged commit 8f0498c into main May 28, 2026
6 checks passed
@arnaudlh arnaudlh deleted the fix/release-drop-odd-minor-prerelease branch May 28, 2026 00:13
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.

3 participants