Skip to content

Node.js Package

Node.js Package #8

Workflow file for this run

# This workflow will run tests using node and then publish a package to NPM
name: Node.js Package
on:
workflow_dispatch
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v3.8.1
with:
node-version: 20
- run: npm install
- run: npm run test
publish-npm:
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v3.8.1
with:
node-version: 20
registry-url: https://registry.npmjs.org/
- run: npm install
- run: npm publish --access public
env:
NODE_AUTH_TOKEN: ${{secrets.npm_token}}