Skip to content

Publish

Publish #3

Workflow file for this run

name: Publish
on:
workflow_dispatch:
inputs:
version:
description: "Version"
required: true
default: "1.x.x"
jobs:
publish:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: "18"
registry-url: "https://registry.npmjs.org"
- run: |
git config --global user.name "${{ github.actor }}"
git config --global user.email "${{ github.actor }}@users.noreply.github.com"
npm version ${{ github.event.inputs.version }}
npm ci
npm run build
(cd ./demo && npm install)
npm publish
git commit --amend -am "Release version ${{ github.event.inputs.version }}"
git push origin
git push origin "v${{ github.event.inputs.version }}"
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}