Skip to content

Semantic Release

Semantic Release #375

name: Semantic Release
on:
workflow_run:
workflows: [Test]
branches: [main]
types:
- completed
# Tests cannot run on windows due to issues with the windows server 2019 images
# the github action runners are using not being able to run linux docker images
# https://github.com/actions/virtual-environments/issues/1143
permissions:
contents: read # for checkout
jobs:
release:
name: Release
runs-on: ubuntu-latest
permissions:
contents: write # to be able to publish a GitHub release
issues: write # to be able to comment on released issues
pull-requests: write # to be able to comment on released pull requests
id-token: write # to enable use of OIDC for trusted publishing and npm provenance
steps:
- name: Checkout
uses: actions/checkout@v6
with:
fetch-depth: 0
- name: Setup Node.js
uses: actions/setup-node@v6
with:
node-version: 'lts/*'
cache: 'npm'
- run: npm ci
- run: npx semantic-release@25
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}