Skip to content

Commit 1a51521

Browse files
author
Shaw
committed
chore: prepare 2.0.0-beta.0 release
1 parent 2ec4b09 commit 1a51521

315 files changed

Lines changed: 1302 additions & 673 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/android-release.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ on:
99
type: string
1010
default: internal
1111
version_name:
12-
description: "Version name (e.g. 2.0.0-alpha.82)"
12+
description: "Version name (e.g. 2.0.0-beta.0)"
1313
required: true
1414
type: string
1515
secrets:
@@ -34,7 +34,7 @@ on:
3434
- production
3535
default: internal
3636
version_name:
37-
description: "Version name (e.g. 2.0.0-alpha.82)"
37+
description: "Version name (e.g. 2.0.0-beta.0)"
3838
required: false
3939
type: string
4040

@@ -87,7 +87,7 @@ jobs:
8787
fi
8888
8989
# Generate version code from version string
90-
# 2.0.0-alpha.82 -> 2000082, 2.1.3 -> 2001003
90+
# 2.0.0-beta.0 -> 2000000, 2.1.3 -> 2001003
9191
MAJOR=$(echo "$VERSION_NAME" | cut -d. -f1)
9292
MINOR=$(echo "$VERSION_NAME" | cut -d. -f2 | cut -d- -f1)
9393
PATCH=$(echo "$VERSION_NAME" | cut -d. -f3 | cut -d- -f1)
@@ -204,7 +204,7 @@ jobs:
204204
run: |
205205
if [[ "${{ github.event_name }}" == "workflow_dispatch" ]]; then
206206
echo "track=${{ inputs.track }}" >> "$GITHUB_OUTPUT"
207-
elif echo "${{ needs.build-aab.outputs.version_name }}" | grep -qE '(alpha|beta|rc)'; then
207+
elif echo "${{ needs.build-aab.outputs.version_name }}" | grep -qE '(beta|rc)'; then
208208
echo "track=internal" >> "$GITHUB_OUTPUT"
209209
else
210210
echo "track=production" >> "$GITHUB_OUTPUT"

.github/workflows/apple-store-release.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ on:
1414
type: string
1515
default: testflight
1616
version:
17-
description: "Version override (e.g. 2.0.0-alpha.82)"
17+
description: "Version override (e.g. 2.0.0-beta.0)"
1818
required: true
1919
type: string
2020
secrets:
@@ -64,7 +64,7 @@ on:
6464
- app-store
6565
default: testflight
6666
version:
67-
description: "Version override (e.g. 2.0.0-alpha.82)"
67+
description: "Version override (e.g. 2.0.0-beta.0)"
6868
required: false
6969
type: string
7070

.github/workflows/publish-packages.yml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ on:
66
workflow_call:
77
inputs:
88
version:
9-
description: "Version to publish (e.g. 2.0.0-alpha.7)"
9+
description: "Version to publish (e.g. 2.0.0-beta.0)"
1010
required: true
1111
type: string
1212
pypi:
@@ -39,7 +39,7 @@ on:
3939
workflow_dispatch:
4040
inputs:
4141
version:
42-
description: "Version to publish (e.g. 2.0.0-alpha.7)"
42+
description: "Version to publish (e.g. 2.0.0-beta.0)"
4343
required: true
4444
type: string
4545
pypi:
@@ -87,16 +87,16 @@ jobs:
8787
echo "version=$VERSION" >> "$GITHUB_OUTPUT"
8888
echo "npm_version=$VERSION" >> "$GITHUB_OUTPUT"
8989
90-
# PEP 440 conversion: 2.0.0-alpha.7 → 2.0.0a7
91-
PYPI_VERSION=$(echo "$VERSION" | sed -E 's/-alpha\.?/a/; s/-beta\.?/b/; s/-rc\.?/rc/')
90+
# PEP 440 conversion: 2.0.0-beta.0 → 2.0.0b0
91+
PYPI_VERSION=$(echo "$VERSION" | sed -E 's/-beta\.?/b/; s/-rc\.?/rc/')
9292
echo "pypi_version=$PYPI_VERSION" >> "$GITHUB_OUTPUT"
9393
94-
# Debian version: 2.0.0-alpha.7 → 2.0.0~alpha7-1
95-
DEB_VERSION=$(echo "$VERSION" | sed -E 's/-alpha\./~alpha/; s/-beta\./~beta/; s/-rc\./~rc/')
94+
# Debian version: 2.0.0-beta.0 → 2.0.0~beta0-1
95+
DEB_VERSION=$(echo "$VERSION" | sed -E 's/-beta\./~beta/; s/-rc\./~rc/')
9696
echo "deb_version=${DEB_VERSION}-1" >> "$GITHUB_OUTPUT"
9797
9898
# Pre-release detection
99-
if echo "$VERSION" | grep -qE '(alpha|beta|rc)'; then
99+
if echo "$VERSION" | grep -qE '(beta|rc)'; then
100100
echo "is_prerelease=true" >> "$GITHUB_OUTPUT"
101101
else
102102
echo "is_prerelease=false" >> "$GITHUB_OUTPUT"
@@ -105,7 +105,7 @@ jobs:
105105
echo "Version: $VERSION"
106106
echo "PyPI: $PYPI_VERSION"
107107
echo "Debian: ${DEB_VERSION}-1"
108-
echo "Pre-release: $(echo "$VERSION" | grep -qE '(alpha|beta|rc)' && echo true || echo false)"
108+
echo "Pre-release: $(echo "$VERSION" | grep -qE '(beta|rc)' && echo true || echo false)"
109109
110110
- name: Check registry credentials
111111
id: registry_credentials

.github/workflows/release-electrobun.yml

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ on:
3636
workflow_call:
3737
inputs:
3838
tag:
39-
description: "Release tag override (e.g. v2.0.0-alpha.3)"
39+
description: "Release tag override (e.g. v2.0.0-beta.0)"
4040
required: false
4141
type: string
4242
draft:
@@ -57,7 +57,7 @@ on:
5757
workflow_dispatch:
5858
inputs:
5959
tag:
60-
description: "Release tag (e.g. v2.0.0-alpha.3)"
60+
description: "Release tag (e.g. v2.0.0-beta.0)"
6161
required: false
6262
type: string
6363
draft:
@@ -94,10 +94,7 @@ jobs:
9494
${{
9595
github.event_name != 'push' ||
9696
(
97-
!contains(github.ref_name, '-alpha') &&
98-
!contains(github.ref_name, '-beta') &&
99-
!contains(github.ref_name, '-rc') &&
100-
!contains(github.ref_name, '-nightly')
97+
!contains(github.ref_name, '-')
10198
)
10299
}}
103100
runs-on: ${{ vars.RUNNER_UBUNTU || 'ubuntu-24.04' }}
@@ -126,7 +123,7 @@ jobs:
126123
fi
127124
VERSION="${TAG#v}"
128125
# canary for pre-release tags, stable for everything else
129-
if echo "$VERSION" | grep -qE '(alpha|beta|rc|nightly)'; then
126+
if [[ "$VERSION" == *"-"* ]]; then
130127
BUILD_ENV="canary"
131128
else
132129
BUILD_ENV="stable"
@@ -1659,7 +1656,7 @@ jobs:
16591656
target_commitish: ${{ needs.prepare.outputs.source_sha }}
16601657
name: Eliza ${{ needs.prepare.outputs.tag }}
16611658
draft: ${{ inputs.draft || false }}
1662-
prerelease: ${{ contains(needs.prepare.outputs.version, 'alpha') || contains(needs.prepare.outputs.version, 'beta') || contains(needs.prepare.outputs.version, 'rc') || contains(needs.prepare.outputs.version, 'nightly') }}
1659+
prerelease: ${{ contains(needs.prepare.outputs.version, '-') }}
16631660
generate_release_notes: true
16641661
files: release-files/*
16651662
env:

.github/workflows/release-orchestrator.yml

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ on:
66
workflow_call:
77
inputs:
88
version:
9-
description: "Version to distribute (e.g. 2.0.0-alpha.87)"
9+
description: "Version to distribute (e.g. 2.0.0-beta.0)"
1010
required: true
1111
type: string
1212
publish_npm:
@@ -42,7 +42,7 @@ on:
4242
workflow_dispatch:
4343
inputs:
4444
version:
45-
description: "Version to distribute (e.g. 2.0.0-alpha.87)"
45+
description: "Version to distribute (e.g. 2.0.0-beta.0)"
4646
required: true
4747
type: string
4848
publish_npm:
@@ -120,7 +120,12 @@ jobs:
120120
ANDROID_TRACK="production"
121121
APPLE_TRACK="app-store"
122122
123-
if echo "$VERSION" | grep -qiE '(alpha|beta|rc|nightly)'; then
123+
if echo "$VERSION" | grep -qi 'alpha'; then
124+
echo "::error::Alpha releases are disabled. Use a beta, rc, nightly, or stable version."
125+
exit 1
126+
fi
127+
128+
if echo "$VERSION" | grep -qiE '(beta|rc|nightly)'; then
124129
IS_PRERELEASE="true"
125130
ANDROID_TRACK="internal"
126131
APPLE_TRACK="testflight"

.github/workflows/release.yaml

Lines changed: 45 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
name: NPM Release
22

33
# Consolidated workflow for all NPM releases:
4-
# - Beta: On merge to main branch
5-
# - Production: On GitHub release creation
4+
# - Beta: On v*-beta.* tags or beta GitHub releases
5+
# - Production: On stable GitHub release creation
66
#
77
# Version Management:
88
# - Uses lerna version and publish commands with consistent patterns
@@ -12,21 +12,10 @@ name: NPM Release
1212

1313
on:
1414
push:
15-
branches:
16-
- main # Triggers beta releases
17-
paths-ignore:
18-
- "**/*.md"
19-
- "docs/**"
20-
- "packages/docs/**"
21-
- ".github/**/*.md"
22-
- "LICENSE"
23-
- ".gitignore"
24-
- ".dockerignore"
25-
- "**/*.example"
26-
- ".vscode/**"
27-
- ".devcontainer/**"
15+
tags:
16+
- "v*"
2817
release:
29-
types: [created] # Triggers production releases
18+
types: [created]
3019
workflow_dispatch:
3120
inputs:
3221
release_type:
@@ -47,12 +36,13 @@ concurrency:
4736
jobs:
4837
release:
4938
runs-on: ubuntu-latest
50-
# Skip if commit message contains [skip ci], and keep prerelease tags
51-
# out of the production/latest GitHub Release path.
39+
# Skip if commit message contains [skip ci]. Alpha releases are disabled;
40+
# beta prereleases are published from tags/releases with the beta dist-tag.
5241
if: >-
5342
${{
5443
!contains(github.event.head_commit.message || '', '[skip ci]') &&
55-
!(github.event_name == 'release' && contains(github.event.release.tag_name || '', '-'))
44+
!(github.event_name == 'release' && contains(github.event.release.tag_name || '', '-alpha')) &&
45+
!(github.ref_type == 'tag' && contains(github.ref_name || '', '-alpha'))
5646
}}
5747
5848
permissions:
@@ -153,21 +143,34 @@ jobs:
153143
id: release_type
154144
run: |
155145
if [[ "${{ github.event_name }}" == "release" ]]; then
156-
echo "type=latest" >> $GITHUB_OUTPUT
157-
echo "dist_tag=latest" >> $GITHUB_OUTPUT
158146
# Extract version from tag (remove 'v' prefix if present)
159147
VERSION="${{ github.event.release.tag_name }}"
160148
VERSION="${VERSION#v}"
149+
if [[ "${VERSION}" == *"-beta."* ]]; then
150+
echo "type=beta" >> $GITHUB_OUTPUT
151+
echo "dist_tag=beta" >> $GITHUB_OUTPUT
152+
else
153+
echo "type=latest" >> $GITHUB_OUTPUT
154+
echo "dist_tag=latest" >> $GITHUB_OUTPUT
155+
fi
156+
echo "version=${VERSION}" >> $GITHUB_OUTPUT
157+
echo "is_release_event=true" >> $GITHUB_OUTPUT
158+
elif [[ "${{ github.ref_type }}" == "tag" ]]; then
159+
VERSION="${{ github.ref_name }}"
160+
VERSION="${VERSION#v}"
161+
if [[ "${VERSION}" == *"-beta."* ]]; then
162+
echo "type=beta" >> $GITHUB_OUTPUT
163+
echo "dist_tag=beta" >> $GITHUB_OUTPUT
164+
else
165+
echo "type=latest" >> $GITHUB_OUTPUT
166+
echo "dist_tag=latest" >> $GITHUB_OUTPUT
167+
fi
161168
echo "version=${VERSION}" >> $GITHUB_OUTPUT
162169
echo "is_release_event=true" >> $GITHUB_OUTPUT
163170
elif [[ "${{ github.event_name }}" == "workflow_dispatch" ]]; then
164171
echo "type=${{ github.event.inputs.release_type }}" >> $GITHUB_OUTPUT
165172
echo "dist_tag=${{ github.event.inputs.release_type }}" >> $GITHUB_OUTPUT
166173
echo "is_release_event=false" >> $GITHUB_OUTPUT
167-
elif [[ "${{ github.ref }}" == "refs/heads/main" ]]; then
168-
echo "type=beta" >> $GITHUB_OUTPUT
169-
echo "dist_tag=beta" >> $GITHUB_OUTPUT
170-
echo "is_release_event=false" >> $GITHUB_OUTPUT
171174
fi
172175
173176
# Version Management
@@ -214,10 +217,10 @@ jobs:
214217
}
215218
216219
# Determine version strategy based on release type and current version
217-
if [[ "${{ github.event_name }}" == "release" ]]; then
218-
# Production release from GitHub release tag
220+
if [[ "${{ steps.release_type.outputs.is_release_event }}" == "true" ]]; then
221+
# Tagged release from git tag or GitHub release tag
219222
VERSION="${{ steps.release_type.outputs.version }}"
220-
echo "📦 Production release: Setting exact version to ${VERSION}"
223+
echo "📦 Tagged release: Setting exact version to ${VERSION}"
221224
bunx lerna version ${VERSION} \
222225
--force-publish \
223226
--yes \
@@ -734,16 +737,16 @@ jobs:
734737
735738
# Compare versions and auto-advance if needed
736739
if [[ "$DEVELOP_BASE" < "$BASE_VERSION" ]]; then
737-
# Develop is behind - update it to match production with alpha suffix
738-
NEXT_ALPHA="${BASE_VERSION}-alpha.0"
740+
# Develop is behind - update it to match production with beta suffix
741+
NEXT_BETA="${BASE_VERSION}-beta.0"
739742
740-
echo "Develop is behind: ${DEVELOP_VERSION} → ${NEXT_ALPHA}"
743+
echo "Develop is behind: ${DEVELOP_VERSION} → ${NEXT_BETA}"
741744
742745
# Create a branch for the sync (using release/ prefix for lerna)
743746
git checkout -b release/sync-develop-${BASE_VERSION} origin/develop
744747
745-
# Update version to match production base with alpha suffix
746-
bunx lerna version ${NEXT_ALPHA} \
748+
# Update version to match production base with beta suffix
749+
bunx lerna version ${NEXT_BETA} \
747750
--force-publish \
748751
--yes \
749752
--no-private \
@@ -756,12 +759,12 @@ jobs:
756759
757760
# Commit
758761
git add -A
759-
git commit -m "chore: sync to v${NEXT_ALPHA} after v${BASE_VERSION} release [skip ci]" \
762+
git commit -m "chore: sync to v${NEXT_BETA} after v${BASE_VERSION} release [skip ci]" \
760763
-m "Automated version sync from production release"
761764
762765
# Push to develop
763766
if git push origin HEAD:develop; then
764-
echo "✅ Successfully synced develop to ${NEXT_ALPHA}"
767+
echo "✅ Successfully synced develop to ${NEXT_BETA}"
765768
else
766769
echo "⚠️ Could not push to develop (may be protected or already updated)"
767770
fi
@@ -772,15 +775,15 @@ jobs:
772775
# Calculate next patch version
773776
IFS='.' read -r major minor patch <<< "$BASE_VERSION"
774777
NEXT_PATCH="${major}.${minor}.$((patch + 1))"
775-
NEXT_ALPHA="${NEXT_PATCH}-alpha.0"
778+
NEXT_BETA="${NEXT_PATCH}-beta.0"
776779
777-
echo "Auto-advancing: ${DEVELOP_VERSION} → ${NEXT_ALPHA}"
780+
echo "Auto-advancing: ${DEVELOP_VERSION} → ${NEXT_BETA}"
778781
779782
# Create a branch for the sync (using release/ prefix for lerna)
780783
git checkout -b release/sync-develop-${BASE_VERSION} origin/develop
781784
782-
# Update version to next patch with alpha suffix
783-
bunx lerna version ${NEXT_ALPHA} \
785+
# Update version to next patch with beta suffix
786+
bunx lerna version ${NEXT_BETA} \
784787
--force-publish \
785788
--yes \
786789
--no-private \
@@ -793,12 +796,12 @@ jobs:
793796
794797
# Commit
795798
git add -A
796-
git commit -m "chore: bump to v${NEXT_ALPHA} after v${BASE_VERSION} release [skip ci]" \
799+
git commit -m "chore: bump to v${NEXT_BETA} after v${BASE_VERSION} release [skip ci]" \
797800
-m "Automated patch version bump from production release"
798801
799802
# Push to develop
800803
if git push origin HEAD:develop; then
801-
echo "✅ Successfully auto-advanced develop to ${NEXT_ALPHA}"
804+
echo "✅ Successfully auto-advanced develop to ${NEXT_BETA}"
802805
else
803806
echo "⚠️ Could not push to develop (may be protected or already updated)"
804807
fi
@@ -837,7 +840,7 @@ jobs:
837840
838841
if [[ -z "${NEW_DEVELOP_BASE}" ]]; then
839842
git checkout origin/develop -- lerna.json 2>/dev/null || true
840-
NEW_DEVELOP_VERSION=$(node -p "require('./lerna.json').version" 2>/dev/null || echo "${BASE_VERSION}-alpha.0")
843+
NEW_DEVELOP_VERSION=$(node -p "require('./lerna.json').version" 2>/dev/null || echo "${BASE_VERSION}-beta.0")
841844
NEW_DEVELOP_BASE=$(echo "$NEW_DEVELOP_VERSION" | sed 's/-.*$//')
842845
git checkout HEAD -- lerna.json
843846
fi

.github/workflows/sync-next-dist-tags.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ on:
99
source_tag:
1010
description: Source dist-tag to mirror
1111
required: false
12-
default: alpha
12+
default: beta
1313
type: string
1414
target_tag:
1515
description: Target dist-tag to update
@@ -40,4 +40,4 @@ jobs:
4040
AUTH_NPMRC="${NPM_CONFIG_USERCONFIG:-$HOME/.npmrc}"
4141
mkdir -p "$(dirname "$AUTH_NPMRC")"
4242
echo "//registry.npmjs.org/:_authToken=${NODE_AUTH_TOKEN}" > "$AUTH_NPMRC"
43-
node scripts/sync-prerelease-dist-tags.js "${{ inputs.source_tag || 'alpha' }}" "${{ inputs.target_tag || 'next' }}"
43+
node scripts/sync-prerelease-dist-tags.js "${{ inputs.source_tag || 'beta' }}" "${{ inputs.target_tag || 'next' }}"

0 commit comments

Comments
 (0)