From b52fdb827745050042e851f7535a8f6faf3b959a Mon Sep 17 00:00:00 2001 From: Jason Williams Date: Sun, 14 Sep 2025 00:34:33 +0100 Subject: [PATCH 01/13] feat: implement alpha/beta release strategy MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Update workflows for feature/* → alpha, beta/* → beta, main → stable - Reset version to 0.1.0 for clean slate - Add release strategy documentation - Update README with alpha/beta installation instructions --- .github/workflows/beta.yml | 38 +++++++++++--- .releaserc.json | 43 ++++++++++++++-- README.md | 16 ++++++ docs/RELEASE_STRATEGY.md | 101 +++++++++++++++++++++++++++++++++++++ package.json | 2 +- 5 files changed, 187 insertions(+), 13 deletions(-) create mode 100644 docs/RELEASE_STRATEGY.md diff --git a/.github/workflows/beta.yml b/.github/workflows/beta.yml index 22cbc30..c2bbf03 100644 --- a/.github/workflows/beta.yml +++ b/.github/workflows/beta.yml @@ -1,14 +1,13 @@ -name: Beta Prerelease +name: Alpha/Beta Prerelease on: push: branches: - - 'story/**' - 'feature/**' - - 'release/**' + - 'beta/**' jobs: - beta: + prerelease: if: github.event_name == 'push' runs-on: ubuntu-latest permissions: @@ -29,14 +28,36 @@ jobs: NODE_AUTH_TOKEN: ${{ secrets.NODE_AUTH_TOKEN }} run: npm whoami || true - run: npm run build --if-present - - name: Bump prerelease version (beta) without tagging + + - name: Determine release type + id: release-type + shell: bash + run: | + if [[ "${{ github.ref }}" == refs/heads/feature/* ]]; then + echo "type=alpha" >> $GITHUB_OUTPUT + echo "preid=alpha" >> $GITHUB_OUTPUT + echo "tag=alpha" >> $GITHUB_OUTPUT + echo "Release type: ALPHA (experimental features)" + elif [[ "${{ github.ref }}" == refs/heads/beta/* ]]; then + echo "type=beta" >> $GITHUB_OUTPUT + echo "preid=beta" >> $GITHUB_OUTPUT + echo "tag=beta" >> $GITHUB_OUTPUT + echo "Release type: BETA (testing phase)" + else + echo "type=unknown" >> $GITHUB_OUTPUT + echo "Unknown branch pattern, skipping release" + exit 1 + fi + + - name: Bump prerelease version shell: bash run: | CURRENT=$(node -p "require('./package.json').version") echo "Current version: $CURRENT" - npm version prerelease --preid=beta --no-git-tag-version + npm version prerelease --preid=${{ steps.release-type.outputs.preid }} --no-git-tag-version NEW=$(node -p "require('./package.json').version") echo "New version: $NEW" + - name: Skip if version already exists id: exists shell: bash @@ -49,9 +70,10 @@ jobs: else echo "exists=false" >> $GITHUB_OUTPUT fi - - name: Publish to npm (beta tag) + + - name: Publish to npm if: steps.exists.outputs.exists == 'false' env: NODE_AUTH_TOKEN: ${{ secrets.NODE_AUTH_TOKEN }} NPM_TOKEN: ${{ secrets.NODE_AUTH_TOKEN }} - run: npm publish --tag beta --provenance --access public + run: npm publish --tag ${{ steps.release-type.outputs.tag }} --provenance --access public diff --git a/.releaserc.json b/.releaserc.json index 29a946b..3bdd97d 100644 --- a/.releaserc.json +++ b/.releaserc.json @@ -1,10 +1,45 @@ { - "branches": ["main"], + "branches": [ + "main", + { + "name": "beta", + "prerelease": true + } + ], "plugins": [ - ["@semantic-release/commit-analyzer", { "preset": "conventionalcommits" }], + [ + "@semantic-release/commit-analyzer", + { + "preset": "conventionalcommits", + "releaseRules": [ + { "type": "feat", "release": "minor" }, + { "type": "fix", "release": "patch" }, + { "type": "perf", "release": "patch" }, + { "type": "revert", "release": "patch" }, + { "type": "docs", "release": "patch" }, + { "type": "style", "release": "patch" }, + { "type": "chore", "release": "patch" }, + { "type": "refactor", "release": "patch" }, + { "type": "test", "release": "patch" }, + { "type": "build", "release": "patch" }, + { "type": "ci", "release": "patch" } + ] + } + ], ["@semantic-release/release-notes-generator", { "preset": "conventionalcommits" }], ["@semantic-release/changelog", { "changelogFile": "CHANGELOG.md" }], - "@semantic-release/npm", - ["@semantic-release/github", { "assets": [] }] + [ + "@semantic-release/npm", + { + "npmPublish": true, + "tarballDir": "dist" + } + ], + [ + "@semantic-release/github", + { + "assets": ["dist/*.tgz"] + } + ] ] } diff --git a/README.md b/README.md index 6a235b0..6d1387d 100644 --- a/README.md +++ b/README.md @@ -9,9 +9,23 @@ You can change your model any time. In a terminal, run `openrouter models` to br ## Install +### Stable Release (Recommended) + - Global: `npm i -g @letuscode/openrouter-cli` - One‑off: `npx @letuscode/openrouter-cli --help` +### Beta Release (Testing) + +- Global: `npm i -g @letuscode/openrouter-cli@beta` +- One‑off: `npx @letuscode/openrouter-cli@beta --help` + +### Alpha Release (Experimental) + +- Global: `npm i -g @letuscode/openrouter-cli@alpha` +- One‑off: `npx @letuscode/openrouter-cli@alpha --help` + +> **Note**: This project is in MVP development. Alpha releases are experimental, beta releases are for testing, and stable releases are for general use. See [Release Strategy](docs/RELEASE_STRATEGY.md) for details. + Tip: Running `openrouter` with no args starts the setup wizard and then opens the REPL (in a terminal). ### Requirements @@ -97,3 +111,5 @@ Pick 1-10 or type a model id: ## License - MIT + +# Test alpha release diff --git a/docs/RELEASE_STRATEGY.md b/docs/RELEASE_STRATEGY.md new file mode 100644 index 0000000..6ca6e26 --- /dev/null +++ b/docs/RELEASE_STRATEGY.md @@ -0,0 +1,101 @@ +# Release Strategy + +This document outlines our release strategy for the OpenRouter CLI project during its MVP development phase. + +## Branch Strategy + +### Feature Branches (`feature/*`) + +- **Purpose**: Experimental features and new functionality +- **Release Type**: Alpha releases +- **NPM Tag**: `alpha` +- **Version Pattern**: `0.1.0-alpha.1`, `0.1.0-alpha.2`, etc. +- **When to use**: When developing new features that may have breaking changes + +### Beta Branches (`beta/*`) + +- **Purpose**: Feature-complete functionality ready for testing +- **Release Type**: Beta releases +- **NPM Tag**: `beta` +- **Version Pattern**: `0.1.0-beta.1`, `0.1.0-beta.2`, etc. +- **When to use**: When features are complete and ready for broader testing + +### Main Branch (`main`) + +- **Purpose**: Stable, production-ready releases +- **Release Type**: Stable releases +- **NPM Tag**: `latest` +- **Version Pattern**: `0.1.0`, `0.1.1`, `0.2.0`, etc. +- **When to use**: When features are thoroughly tested and stable + +## Development Workflow + +1. **Create feature branch**: `feature/your-feature-name` +2. **Develop feature**: Push commits → Automatic alpha releases +3. **Merge to beta**: `beta/your-feature-name` +4. **Test thoroughly**: Push commits → Automatic beta releases +5. **Merge to main**: When ready → Automatic stable release + +## Quality Gates + +### Alpha Releases + +- ✅ Feature implemented +- ⚠️ May have breaking changes +- ⚠️ May have bugs +- 🎯 Target: Early adopters and internal testing + +### Beta Releases + +- ✅ Feature complete +- ✅ Basic testing done +- ⚠️ May have minor bugs +- 🎯 Target: Broader testing community + +### Stable Releases + +- ✅ Feature complete +- ✅ Thoroughly tested +- ✅ No known critical bugs +- ✅ Documentation updated +- 🎯 Target: General users + +## Version Constraints + +- **No 1.x.x releases** until truly production-ready +- **Stays in 0.x.x range** during MVP development +- **Semantic versioning** within 0.x.x range + +## NPM Installation + +```bash +# Install latest stable release +npm install @letuscode/openrouter-cli + +# Install latest beta release +npm install @letuscode/openrouter-cli@beta + +# Install latest alpha release +npm install @letuscode/openrouter-cli@alpha + +# Install specific version +npm install @letuscode/openrouter-cli@0.1.0-beta.1 +``` + +## GitHub Releases + +- **Alpha/Beta**: Created automatically on feature/beta branches +- **Stable**: Created automatically on main branch +- **Tags**: Follow semantic versioning (v0.1.0, v0.1.0-alpha.1, etc.) + +## When to Release to Main + +A feature is ready for main when: + +- [ ] Feature is complete and tested +- [ ] No breaking changes (or breaking changes are documented) +- [ ] All tests pass +- [ ] Documentation is updated +- [ ] Beta testing shows no critical issues +- [ ] Performance is acceptable +- [ ] Security review completed (if applicable) diff --git a/package.json b/package.json index f3433e3..5d0a043 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@letuscode/openrouter-cli", - "version": "1.0.0-beta.1", + "version": "0.1.0", "description": "CLI tool for OpenRouter (OpenAI-compatible)", "bin": { "openrouter": "bin/openrouter" From f50f7bbd4e3ff4e72a873c1e4f5f5877e0e2f86c Mon Sep 17 00:00:00 2001 From: Jason Williams Date: Sun, 14 Sep 2025 00:46:35 +0100 Subject: [PATCH 02/13] fix: add GitHub release creation to alpha/beta workflow --- .github/workflows/beta.yml | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/.github/workflows/beta.yml b/.github/workflows/beta.yml index c2bbf03..37f8c08 100644 --- a/.github/workflows/beta.yml +++ b/.github/workflows/beta.yml @@ -77,3 +77,18 @@ jobs: NODE_AUTH_TOKEN: ${{ secrets.NODE_AUTH_TOKEN }} NPM_TOKEN: ${{ secrets.NODE_AUTH_TOKEN }} run: npm publish --tag ${{ steps.release-type.outputs.tag }} --provenance --access public + + - name: Create GitHub Release + if: steps.exists.outputs.exists == 'false' + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + run: | + PKG=$(node -p "require('./package.json').name") + VER=$(node -p "require('./package.json').version") + TAG="v$VER" + + # Create GitHub release + gh release create "$TAG" \ + --title "$TAG" \ + --notes "**${{ steps.release-type.outputs.type | upper }} Release** - ${{ steps.release-type.outputs.type | upper }} version $VER" \ + --prerelease From ceb03732a219a7e8a17b175ef8021759dd325f63 Mon Sep 17 00:00:00 2001 From: Jason Williams Date: Sun, 14 Sep 2025 00:47:41 +0100 Subject: [PATCH 03/13] test: verify GitHub release creation --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index 6d1387d..1ae27f8 100644 --- a/README.md +++ b/README.md @@ -113,3 +113,5 @@ Pick 1-10 or type a model id: - MIT # Test alpha release + +# Testing GitHub release creation From 1119383524bfc19b9ed3f4f5ceedbeb49d1acdf8 Mon Sep 17 00:00:00 2001 From: Jason Williams Date: Sun, 14 Sep 2025 00:49:49 +0100 Subject: [PATCH 04/13] fix: correct GitHub Actions syntax for uppercase conversion --- .github/workflows/beta.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/beta.yml b/.github/workflows/beta.yml index 37f8c08..757b7d6 100644 --- a/.github/workflows/beta.yml +++ b/.github/workflows/beta.yml @@ -86,9 +86,11 @@ jobs: PKG=$(node -p "require('./package.json').name") VER=$(node -p "require('./package.json').version") TAG="v$VER" + TYPE="${{ steps.release-type.outputs.type }}" + TYPE_UPPER=$(echo "$TYPE" | tr '[:lower:]' '[:upper:]') # Create GitHub release gh release create "$TAG" \ --title "$TAG" \ - --notes "**${{ steps.release-type.outputs.type | upper }} Release** - ${{ steps.release-type.outputs.type | upper }} version $VER" \ + --notes "**${TYPE_UPPER} Release** - ${TYPE_UPPER} version $VER" \ --prerelease From 2394edcda2b85f5d290ae4287b676ce68a400012 Mon Sep 17 00:00:00 2001 From: Jason Williams Date: Sun, 14 Sep 2025 00:51:14 +0100 Subject: [PATCH 05/13] test: final alpha workflow test --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index 1ae27f8..43c569e 100644 --- a/README.md +++ b/README.md @@ -115,3 +115,5 @@ Pick 1-10 or type a model id: # Test alpha release # Testing GitHub release creation + +# Final test of alpha workflow From 0f85b11a41165e81796199c15ae5a3dc3c72f31b Mon Sep 17 00:00:00 2001 From: Jason Williams Date: Sun, 14 Sep 2025 00:53:15 +0100 Subject: [PATCH 06/13] fix: improve prerelease version bumping logic --- .github/workflows/beta.yml | 26 +++++++++++++++++++++++--- 1 file changed, 23 insertions(+), 3 deletions(-) diff --git a/.github/workflows/beta.yml b/.github/workflows/beta.yml index 757b7d6..2fc77de 100644 --- a/.github/workflows/beta.yml +++ b/.github/workflows/beta.yml @@ -54,9 +54,29 @@ jobs: run: | CURRENT=$(node -p "require('./package.json').version") echo "Current version: $CURRENT" - npm version prerelease --preid=${{ steps.release-type.outputs.preid }} --no-git-tag-version - NEW=$(node -p "require('./package.json').version") - echo "New version: $NEW" + + # Get the latest version from NPM for this prerelease type + PKG=$(node -p "require('./package.json').name") + PREID="${{ steps.release-type.outputs.preid }}" + + # Try to get the latest prerelease version from NPM + LATEST_PRERELEASE=$(npm view "$PKG" versions --json | jq -r ".[] | select(startswith(\"0.1.\") and contains(\"-$PREID.\"))" | tail -1) || echo "" + + if [ -n "$LATEST_PRERELEASE" ]; then + echo "Latest prerelease version: $LATEST_PRERELEASE" + # Extract the prerelease number and increment it + PRERELEASE_NUM=$(echo "$LATEST_PRERELEASE" | sed "s/.*-$PREID\.//") + NEW_PRERELEASE_NUM=$((PRERELEASE_NUM + 1)) + NEW_VERSION="0.1.1-$PREID.$NEW_PRERELEASE_NUM" + else + # No prerelease version exists, start with .0 + NEW_VERSION="0.1.1-$PREID.0" + fi + + echo "Setting version to: $NEW_VERSION" + npm version "$NEW_VERSION" --no-git-tag-version + VERIFIED=$(node -p "require('./package.json').version") + echo "Verified version: $VERIFIED" - name: Skip if version already exists id: exists From 4e1ed5ba4dcf91fd0c41b3699730c02fc9fedce2 Mon Sep 17 00:00:00 2001 From: Jason Williams Date: Sun, 14 Sep 2025 00:53:30 +0100 Subject: [PATCH 07/13] test: improved version bumping logic --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index 43c569e..ce0b3f4 100644 --- a/README.md +++ b/README.md @@ -117,3 +117,5 @@ Pick 1-10 or type a model id: # Testing GitHub release creation # Final test of alpha workflow + +# Testing improved version bumping From 9478f814ebe4ccf67393041d85da48f9000c93b4 Mon Sep 17 00:00:00 2001 From: Jason Williams Date: Sun, 14 Sep 2025 00:58:49 +0100 Subject: [PATCH 08/13] test: verify version incrementing works --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index ce0b3f4..7ea5926 100644 --- a/README.md +++ b/README.md @@ -119,3 +119,5 @@ Pick 1-10 or type a model id: # Final test of alpha workflow # Testing improved version bumping + +# Testing version increment From 517467243e9348514ff54f2278c3e3cbeb8f8d40 Mon Sep 17 00:00:00 2001 From: Jason Williams Date: Sun, 14 Sep 2025 01:00:01 +0100 Subject: [PATCH 09/13] test: verify version incrementing works --- .github/workflows/beta.yml | 26 ++++---------------------- 1 file changed, 4 insertions(+), 22 deletions(-) diff --git a/.github/workflows/beta.yml b/.github/workflows/beta.yml index 2fc77de..a2f42a4 100644 --- a/.github/workflows/beta.yml +++ b/.github/workflows/beta.yml @@ -55,28 +55,10 @@ jobs: CURRENT=$(node -p "require('./package.json').version") echo "Current version: $CURRENT" - # Get the latest version from NPM for this prerelease type - PKG=$(node -p "require('./package.json').name") - PREID="${{ steps.release-type.outputs.preid }}" - - # Try to get the latest prerelease version from NPM - LATEST_PRERELEASE=$(npm view "$PKG" versions --json | jq -r ".[] | select(startswith(\"0.1.\") and contains(\"-$PREID.\"))" | tail -1) || echo "" - - if [ -n "$LATEST_PRERELEASE" ]; then - echo "Latest prerelease version: $LATEST_PRERELEASE" - # Extract the prerelease number and increment it - PRERELEASE_NUM=$(echo "$LATEST_PRERELEASE" | sed "s/.*-$PREID\.//") - NEW_PRERELEASE_NUM=$((PRERELEASE_NUM + 1)) - NEW_VERSION="0.1.1-$PREID.$NEW_PRERELEASE_NUM" - else - # No prerelease version exists, start with .0 - NEW_VERSION="0.1.1-$PREID.0" - fi - - echo "Setting version to: $NEW_VERSION" - npm version "$NEW_VERSION" --no-git-tag-version - VERIFIED=$(node -p "require('./package.json').version") - echo "Verified version: $VERIFIED" + # Simple prerelease bump from current version + npm version prerelease --preid=${{ steps.release-type.outputs.preid }} --no-git-tag-version + NEW=$(node -p "require('./package.json').version") + echo "New version: $NEW" - name: Skip if version already exists id: exists From 7252367a2fab00a630c0121d99a2132221676737 Mon Sep 17 00:00:00 2001 From: Jason Williams Date: Sun, 14 Sep 2025 01:09:09 +0100 Subject: [PATCH 10/13] fix: properly increment alpha versions using dynamic base version --- .github/workflows/beta.yml | 33 +++++++++++++++++++++++++++++---- 1 file changed, 29 insertions(+), 4 deletions(-) diff --git a/.github/workflows/beta.yml b/.github/workflows/beta.yml index a2f42a4..3619de6 100644 --- a/.github/workflows/beta.yml +++ b/.github/workflows/beta.yml @@ -55,10 +55,35 @@ jobs: CURRENT=$(node -p "require('./package.json').version") echo "Current version: $CURRENT" - # Simple prerelease bump from current version - npm version prerelease --preid=${{ steps.release-type.outputs.preid }} --no-git-tag-version - NEW=$(node -p "require('./package.json').version") - echo "New version: $NEW" + # Get the latest alpha version from NPM + PKG=$(node -p "require('./package.json').name") + PREID="${{ steps.release-type.outputs.preid }}" + + # Get the latest alpha version + LATEST_ALPHA=$(npm view "$PKG" versions --json | jq -r ".[] | select(contains(\"-$PREID.\"))" | tail -1) || echo "" + + if [ -n "$LATEST_ALPHA" ]; then + echo "Latest alpha version: $LATEST_ALPHA" + # Extract the prerelease number and increment it + PRERELEASE_NUM=$(echo "$LATEST_ALPHA" | sed "s/.*-$PREID\.//") + NEW_PRERELEASE_NUM=$((PRERELEASE_NUM + 1)) + # Extract base version (e.g., 0.1.1 from 0.1.1-alpha.1) + BASE_VERSION=$(echo "$LATEST_ALPHA" | sed "s/-$PREID\..*//") + NEW_VERSION="$BASE_VERSION-$PREID.$NEW_PRERELEASE_NUM" + else + # No alpha version exists, create first one + npm version patch --no-git-tag-version + PATCH_VERSION=$(node -p "require('./package.json').version") + npm version prerelease --preid=$PREID --no-git-tag-version + NEW=$(node -p "require('./package.json').version") + echo "Created first alpha version: $NEW" + exit 0 + fi + + echo "Setting version to: $NEW_VERSION" + npm version "$NEW_VERSION" --no-git-tag-version + VERIFIED=$(node -p "require('./package.json').version") + echo "Verified version: $VERIFIED" - name: Skip if version already exists id: exists From 5df1d13781edafc501dc25fd280837f9e9001934 Mon Sep 17 00:00:00 2001 From: Jason Williams Date: Sun, 14 Sep 2025 01:11:15 +0100 Subject: [PATCH 11/13] fix: add write permissions for GitHub release creation --- .github/workflows/beta.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/beta.yml b/.github/workflows/beta.yml index 3619de6..72906ca 100644 --- a/.github/workflows/beta.yml +++ b/.github/workflows/beta.yml @@ -11,7 +11,7 @@ jobs: if: github.event_name == 'push' runs-on: ubuntu-latest permissions: - contents: read + contents: write id-token: write steps: - uses: actions/checkout@v4 From 5aa034fa9aff53823b9fd64cb4d690cbe9d73f1b Mon Sep 17 00:00:00 2001 From: Jason Williams Date: Sun, 14 Sep 2025 13:58:14 +0100 Subject: [PATCH 12/13] feat: implement hybrid PR and push-based release workflow for beta and stable releases --- .github/workflows/beta.yml | 25 ++++++++++++++++++++----- 1 file changed, 20 insertions(+), 5 deletions(-) diff --git a/.github/workflows/beta.yml b/.github/workflows/beta.yml index 72906ca..3a0ee1a 100644 --- a/.github/workflows/beta.yml +++ b/.github/workflows/beta.yml @@ -5,10 +5,15 @@ on: branches: - 'feature/**' - 'beta/**' + pull_request: + types: [closed] + branches: + - 'beta/**' + - 'main' jobs: prerelease: - if: github.event_name == 'push' + if: github.event_name == 'push' || (github.event_name == 'pull_request' && github.event.pull_request.merged == true) runs-on: ubuntu-latest permissions: contents: write @@ -33,19 +38,29 @@ jobs: id: release-type shell: bash run: | - if [[ "${{ github.ref }}" == refs/heads/feature/* ]]; then + if [[ "${{ github.event_name }}" == "push" && "${{ github.ref }}" == refs/heads/feature/* ]]; then echo "type=alpha" >> $GITHUB_OUTPUT echo "preid=alpha" >> $GITHUB_OUTPUT echo "tag=alpha" >> $GITHUB_OUTPUT echo "Release type: ALPHA (experimental features)" - elif [[ "${{ github.ref }}" == refs/heads/beta/* ]]; then + elif [[ "${{ github.event_name }}" == "push" && "${{ github.ref }}" == refs/heads/beta/* ]]; then + echo "type=beta" >> $GITHUB_OUTPUT + echo "preid=beta" >> $GITHUB_OUTPUT + echo "tag=beta" >> $GITHUB_OUTPUT + echo "Release type: BETA (testing phase - direct push)" + elif [[ "${{ github.event_name }}" == "pull_request" && "${{ github.base_ref }}" == "beta" ]]; then echo "type=beta" >> $GITHUB_OUTPUT echo "preid=beta" >> $GITHUB_OUTPUT echo "tag=beta" >> $GITHUB_OUTPUT - echo "Release type: BETA (testing phase)" + echo "Release type: BETA (testing phase - PR merge)" + elif [[ "${{ github.event_name }}" == "pull_request" && "${{ github.base_ref }}" == "main" ]]; then + echo "type=stable" >> $GITHUB_OUTPUT + echo "preid=" >> $GITHUB_OUTPUT + echo "tag=latest" >> $GITHUB_OUTPUT + echo "Release type: STABLE (production ready)" else echo "type=unknown" >> $GITHUB_OUTPUT - echo "Unknown branch pattern, skipping release" + echo "Unknown trigger pattern, skipping release" exit 1 fi From 6fc41cde5bf962864994971893dd2e9c1499c225 Mon Sep 17 00:00:00 2001 From: Jason Williams Date: Sun, 14 Sep 2025 14:04:09 +0100 Subject: [PATCH 13/13] fix: filter NPM versions to only use 0.x.x pattern for new versioning --- .github/workflows/beta.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/beta.yml b/.github/workflows/beta.yml index 3a0ee1a..75f3c5a 100644 --- a/.github/workflows/beta.yml +++ b/.github/workflows/beta.yml @@ -74,8 +74,8 @@ jobs: PKG=$(node -p "require('./package.json').name") PREID="${{ steps.release-type.outputs.preid }}" - # Get the latest alpha version - LATEST_ALPHA=$(npm view "$PKG" versions --json | jq -r ".[] | select(contains(\"-$PREID.\"))" | tail -1) || echo "" + # Get the latest alpha version (only 0.x.x versions) + LATEST_ALPHA=$(npm view "$PKG" versions --json | jq -r ".[] | select(startswith(\"0.\") and contains(\"-$PREID.\"))" | tail -1) || echo "" if [ -n "$LATEST_ALPHA" ]; then echo "Latest alpha version: $LATEST_ALPHA"