Skip to content

Package

Package #11

Workflow file for this run

name: Package
on:
workflow_call:
workflow_dispatch:
jobs:
package:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up Node
uses: actions/setup-node@v3
with:
cache: npm
node-version-file: .nvmrc
registry-url: https://npm.pkg.github.com
- name: Install dependencies
run: npm ci --ignore-scripts
- name: Build package
run: |
npm run build
mkdir package
cp -r dist LICENSE.md package.json README.md src package/
- name: Publish package
env:
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: cd package && npm publish