Skip to content

Release to NPM

Release to NPM #31

Workflow file for this run

name: Release to NPM
on:
workflow_run:
workflows: ['CI']
types:
- completed
branches:
- master
permissions:
contents: read
jobs:
release:
if: ${{ github.event.workflow_run.conclusion == 'success' }}
runs-on: ubuntu-latest
permissions:
issues: write
id-token: write
contents: write
pull-requests: write
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 'lts/*'
- name: 'Node and NPM version'
run: node -v && npm -v
- name: Install dependencies
run: npm clean-install
- name: Verify the integrity of installed dependencies
run: npm audit signatures
- name: 'Build package'
run: npm run build
- name: Release
run: npx semantic-release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}