Skip to content

Publish Package

Publish Package #6

name: publish-package
on:
workflow_dispatch:
inputs:
newversion:
description: 'Semantic Version Bump Type (major minor patch)'
required: true
jobs:
release-please:
runs-on: ubuntu-latest
steps:
- name: Checkout repository code
uses: actions/checkout@v4
- name: Install Node
uses: actions/setup-node@v4
with:
node-version: "20.10.0"
registry-url: https://registry.npmjs.org/
- name: Build
run: |
yarn install --immutable --immutable-cache --check-cache
yarn build
yarn pack
- name: Version and publish to npm
id: npm-bump
uses: bcomnes/npm-bump@v2
with:
git_email: [email protected]
git_username: github-actions
newversion: ${{ github.event.inputs.newversion }}
push_version_commit: true
github_token: ${{ secrets.GITHUB_TOKEN }}
npm_token: ${{ secrets.NPM_ACCESS_TOKEN }}