Release v2.0.0-alpha.18 #28
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Publish SDK | |
| on: | |
| release: | |
| types: [published] | |
| workflow_dispatch: | |
| inputs: | |
| dry_run: | |
| description: "Dry run only (no actual publishing)" | |
| required: false | |
| default: false | |
| type: boolean | |
| continue: | |
| description: "Continue publishing even if some packages fail" | |
| required: false | |
| default: false | |
| type: boolean | |
| permissions: | |
| contents: read | |
| id-token: write | |
| jobs: | |
| # Validate versions first | |
| validate: | |
| name: Validate Versions | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Install Bun | |
| uses: oven-sh/setup-bun@v2 | |
| with: | |
| bun-version: 1.2.21 | |
| - name: Code Checkout | |
| uses: actions/checkout@v4 | |
| - name: Install dependencies | |
| run: bun install | |
| - name: Validate package versions | |
| run: bun run validate:versions ${{ github.event.inputs.version }} | |
| # Build SDK package | |
| build-sdk: | |
| name: Build SDK | |
| runs-on: ubuntu-latest | |
| needs: validate | |
| steps: | |
| - name: Install Bun | |
| uses: oven-sh/setup-bun@v2 | |
| with: | |
| bun-version: 1.2.21 | |
| - name: Code Checkout | |
| uses: actions/checkout@v4 | |
| - name: Install dependencies | |
| run: bun install | |
| - name: Build SDK | |
| run: bun run build:sdk | |
| - name: Upload SDK artifacts | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: sdk-artifacts | |
| retention-days: 1 | |
| path: packages/sdk/dist/ | |
| # Dry run publish to verify everything works | |
| dry-run-publish: | |
| name: Dry Run Publish | |
| runs-on: ubuntu-latest | |
| needs: | |
| - build-sdk | |
| - validate | |
| steps: | |
| - name: Install Bun | |
| uses: oven-sh/setup-bun@v2 | |
| with: | |
| bun-version: 1.2.21 | |
| - name: Code Checkout | |
| uses: actions/checkout@v4 | |
| - name: Install dependencies | |
| run: bun install | |
| - name: Download SDK artifacts | |
| uses: actions/download-artifact@v4 | |
| with: | |
| name: sdk-artifacts | |
| path: packages/sdk/dist/ | |
| - name: Distribution summary | |
| run: | | |
| tree packages/sdk -I src | |
| - name: Dry run publish all packages | |
| run: bun run deploy:sdk --dry-run ${{ github.event.inputs.continue == 'true' && '--continue' || '' }} | |
| # Actual publish (only if not dry run) | |
| publish: | |
| name: Publish Packages | |
| if: ${{ !github.event.inputs.dry_run || github.event.inputs.dry_run == 'false' }} | |
| runs-on: ubuntu-latest | |
| needs: | |
| - build-sdk | |
| - validate | |
| - dry-run-publish | |
| steps: | |
| - name: Install Bun | |
| uses: oven-sh/setup-bun@v2 | |
| with: | |
| bun-version: 1.2.21 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: 24 | |
| registry-url: https://registry.npmjs.org | |
| - name: Code Checkout | |
| uses: actions/checkout@v4 | |
| - name: Install dependencies | |
| run: bun install | |
| - name: Download SDK artifacts | |
| uses: actions/download-artifact@v4 | |
| with: | |
| name: sdk-artifacts | |
| path: packages/sdk/dist/ | |
| - name: Publish all packages | |
| run: bun run deploy:sdk ${{ github.event.inputs.continue == 'true' && '--continue' || '' }} |