chore: Version bump 1.1.0 #15
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: Release | |
| on: | |
| push: | |
| tags: | |
| - "v*" | |
| workflow_dispatch: | |
| inputs: | |
| move-tags: | |
| default: false | |
| description: Allow tags to be moved? Requires GitHub Release. | |
| required: false | |
| type: boolean | |
| publish-github-release: | |
| default: false | |
| description: Create a GitHub release? | |
| required: false | |
| type: boolean | |
| publish-npm: | |
| default: false | |
| description: Publish npm package? | |
| type: boolean | |
| required: false | |
| release-tag: | |
| default: latest | |
| description: Floating release tag to use. | |
| type: string | |
| required: true | |
| concurrency: | |
| group: release | |
| cancel-in-progress: false | |
| env: | |
| # renovate: datasource=node-version depName=node versioning=node | |
| NODE_VERSION: "22.15.0" | |
| jobs: | |
| params: | |
| name: Determine configuration | |
| outputs: | |
| move-tags: ${{ github.event_name == 'workflow_dispatch' && inputs.move-tags || 'true' }} | |
| publish-github-release: ${{ github.event_name == 'workflow_dispatch' && inputs.publish-github-release || 'true' }} | |
| publish-npm: ${{ github.event_name == 'workflow_dispatch' && inputs.publish-npm || 'true' }} | |
| release-tag: ${{ github.event_name == 'workflow_dispatch' && inputs.release-tag || 'latest' }} | |
| release-channel: stable | |
| permissions: | |
| contents: none | |
| runs-on: ubuntu-24.04 | |
| steps: | |
| - if: false | |
| name: Noop | |
| run: exit 0 | |
| changelog: | |
| name: Changelog | |
| needs: | |
| - params | |
| outputs: | |
| version: ${{ steps.changelog.outputs.version-current }} | |
| permissions: | |
| contents: read | |
| runs-on: ubuntu-24.04 | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 | |
| with: | |
| persist-credentials: false | |
| sparse-checkout: package.json | |
| sparse-checkout-cone-mode: false | |
| - id: version | |
| name: Extract current version | |
| run: echo "root-version=$(jq --raw-output '.version' package.json)" >> $GITHUB_OUTPUT | |
| - id: changelog | |
| name: Generate changelog | |
| uses: oliversalzburg/action-automatic-semantic-releases@67ff1f7a549647789a1395859ebcf84fc5951d01 # v0.5.9 | |
| with: | |
| changelog-artifact: changelog.json | |
| dry-run: true | |
| publish: false | |
| repo-token: ${{ secrets.GITHUB_TOKEN }} | |
| root-version: ${{ steps.version.outputs.root-version }} | |
| - name: Store changelog | |
| uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4 | |
| with: | |
| name: changelog.json | |
| path: changelog.json | |
| qa: | |
| name: 🔹 QA | |
| uses: ./.github/workflows/qa-main.yml | |
| publish-npm: | |
| if: success() && needs.params.outputs.publish-npm == 'true' | |
| name: 🔹 Publish | |
| needs: | |
| - changelog | |
| - params | |
| - qa | |
| permissions: | |
| contents: write | |
| id-token: write | |
| packages: write | |
| pages: write | |
| pull-requests: read | |
| secrets: | |
| NPM_TOKEN: ${{ secrets.NPM_TOKEN }} | |
| uses: oliversalzburg/workflows/.github/workflows/frag-publish-npm.yml@main | |
| with: | |
| dist-tag: ${{ needs.params.outputs.release-tag }} | |
| version: ${{ needs.changelog.outputs.version }} | |
| release: | |
| if: | | |
| always() | |
| && contains(needs.*.result, 'success') | |
| && !contains(needs.*.result, 'failure') | |
| && needs.params.outputs.publish-github-release == 'true' | |
| name: Release | |
| needs: | |
| - changelog | |
| - params | |
| - publish-npm | |
| - qa | |
| permissions: | |
| actions: write | |
| attestations: write | |
| contents: write | |
| id-token: write | |
| packages: write | |
| pull-requests: read | |
| runs-on: ubuntu-24.04 | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 | |
| with: | |
| persist-credentials: false | |
| - name: Select Node.js version | |
| uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4 | |
| with: | |
| node-version: ${{ env.NODE_VERSION }} | |
| registry-url: https://registry.npmjs.org | |
| - name: Enable Corepack | |
| run: | | |
| corepack enable | |
| yarn config set enableGlobalCache false | |
| - name: Load cached dependencies | |
| uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # v4 | |
| with: | |
| path: .yarn/cache | |
| key: ${{ runner.os }}-node${{ env.NODE_VERSION }}-${{ hashFiles('**/yarn.lock') }} | |
| restore-keys: ${{ runner.os }}-node${{ env.NODE_VERSION }} | |
| - name: Build release | |
| env: | |
| RELEASE_CHANNEL: ${{ needs.params.outputs.release-channel }} | |
| RELEASE_VERSION: ${{ needs.changelog.outputs.version }} | |
| run: make | |
| - name: Download changelog | |
| uses: actions/download-artifact@d3f86a106a0bac45b974a628896c90dbdf5c8093 # v4 | |
| with: | |
| name: changelog.json | |
| - name: Generate GitHub release | |
| uses: oliversalzburg/action-automatic-semantic-releases@67ff1f7a549647789a1395859ebcf84fc5951d01 # v0.5.9 | |
| with: | |
| body-suffix: | | |
| --- | |
| - Release generated by <${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}> | |
| ${{ needs.publish-npm.outputs.publish-url && format('- npm package published at <{0}>', needs.publish-npm.outputs.publish-url) }} | |
| changelog-artifact: changelog.json | |
| draft: true | |
| dry-run: ${{ needs.params.outputs.move-tags == 'false' }} | |
| merge-similar: true | |
| prerelease: false | |
| repo-token: ${{ secrets.GITHUB_TOKEN }} | |
| title: v${{ needs.changelog.outputs.version }} | |
| with-authors: false |