Skip to content

Publish

Publish #28

Workflow file for this run

name: Publish
env:
PNPM_VERSION: 9.4.0
on:
workflow_dispatch:
inputs:
version:
description: "Version bump"
required: true
type: choice
options:
- patch
- minor
- major
default: "patch"
concurrency:
group: publish-${{ github.ref }}
cancel-in-progress: false
# see: https://docs.github.com/en/actions/publishing-packages/publishing-nodejs-packages
jobs:
publish:
runs-on: ubuntu-latest
permissions:
contents: write
id-token: write
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: "Setup Project"
uses: ./.github/actions/setup-project
- name: "Quality Check"
uses: ./.github/actions/quality-check
- name: "Set commit identity"
run: |
git config --global user.name "GitHub Actions Bot"
git config --global user.email "<>"
- name: "NPM Identity"
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
run: |
echo "//registry.npmjs.org/:_authToken=$NPM_TOKEN" > .npmrc
- name: Publish to GitHub Package Registry
run: |
pnpm version-prepare
lerna publish -y --no-private --no-verify-access ${{inputs.version}}