Skip to content

Publish Package to github packages #9

Publish Package to github packages

Publish Package to github packages #9

Workflow file for this run

name: Publish Package to github packages
on:
release:
types: [published]
jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: write
packages: write
pull-requests: write
checks: write
steps:
- uses: actions/checkout@v4
# Setup .npmrc file to publish to GitHub Packages
- uses: actions/setup-node@v4
with:
node-version: '20.x'
registry-url: 'https://npm.pkg.github.com'
# Defaults to the user or organization that owns the workflow file
scope: '@qualipool'
######
## Update version
######
- name: Bump version in package.json
uses: reedyuk/npm-version@15e0d016f632fe38bbb704910b8359f23262deb7 # 1.2.2
with:
version: ${{ github.event.release.tag_name }}
######
## Build package and publish it to GitHub packages
######
- run: npm ci
- run: npm publish
env:
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}