Skip to content

Commit 92c9fe7

Browse files
committed
ci(release): skip homebrew tap and mcp registry on prerelease tags
Mark GitHub releases as prerelease when the version contains a hyphen (e.g. 2.4.0-beta.1), and gate the update_homebrew_tap and mcp_registry jobs on stable versions only. Without this, a beta tag would overwrite the main Homebrew formula and push beta builds onto every brew install user, and would publish the prerelease to the MCP Registry as if it were the canonical version.
1 parent ccaa40a commit 92c9fe7

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

.github/workflows/release.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ jobs:
158158
files: |
159159
xcodebuildmcp-${{ steps.get_version.outputs.VERSION }}.tgz
160160
draft: false
161-
prerelease: false
161+
prerelease: ${{ contains(steps.get_version.outputs.VERSION, '-') }}
162162

163163
- name: Summary
164164
env:
@@ -176,7 +176,7 @@ jobs:
176176
fi
177177
178178
mcp_registry:
179-
if: github.event_name == 'push'
179+
if: github.event_name == 'push' && !contains(needs.release.outputs.version, '-')
180180
needs: release
181181
runs-on: ubuntu-latest
182182
env:
@@ -391,7 +391,7 @@ jobs:
391391
--repo "$REPOSITORY"
392392
393393
update_homebrew_tap:
394-
if: github.event_name == 'push'
394+
if: github.event_name == 'push' && !contains(needs.release.outputs.version, '-')
395395
needs: [release, build_and_package_macos, publish_portable_assets]
396396
runs-on: ubuntu-latest
397397
env:

0 commit comments

Comments
 (0)