Repository navigation
Merge pull request #39 from carbonteq/changeset-release/main #49
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: Release | |
| on: | |
| push: | |
| branches: | |
| - main | |
| concurrency: ${{ github.workflow }}-${{ github.ref }} | |
| jobs: | |
| release: | |
| permissions: | |
| contents: write | |
| pull-requests: write | |
| name: Release | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout Repo | |
| uses: actions/checkout@v5 | |
| with: | |
| ref: ${{ github.head_ref }} | |
| persist-credentials: true # required for later commit | |
| - name: Setup Bun | |
| uses: oven-sh/setup-bun@v2 | |
| with: | |
| bun-version: latest | |
| - name: Install Dependencies | |
| run: bun install | |
| - name: Build | |
| run: bun run build | |
| - name: Create Release PR or Publish Packages | |
| uses: changesets/action@v1 | |
| id: changesets | |
| with: | |
| title: "🦋 Changeset release" | |
| commit: "chore(changeset): release" | |
| publish: bun run tag | |
| createGithubReleases: true | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Update version for deno/jsr | |
| if: steps.changesets.outputs.published == 'true' | |
| run: node sync_versions.mjs | |
| - name: Format deno.jsonc | |
| if: steps.changesets.outputs.published == 'true' | |
| run: bun run biome format deno.jsonc --write | |
| - name: Commit updated deno.jsonc | |
| if: steps.changesets.outputs.published == 'true' | |
| uses: stefanzweifel/git-auto-commit-action@v7 | |
| with: | |
| commit_message: Update version deno.jsonc | |
| commit_options: "--no-verify --signoff" | |
| file_pattern: deno.jsonc |