Skip to content

ci: add provenance to npm publish (#53) #10

ci: add provenance to npm publish (#53)

ci: add provenance to npm publish (#53) #10

Workflow file for this run

name: npm
on:
push:
tags:
- "*.*.*"
jobs:
package:
runs-on: ubuntu-latest
container: emscripten/emsdk
steps:
-
name: Checkout
uses: actions/checkout@v4
-
name: Delete large LICENSE file
run: rm LICENSE
-
name: Restore node modules cache
uses: actions/cache@v4
with:
path: ./node_modules/
key: npm-${{ hashFiles('package.json') }}
-
name: Install dependencies
run: npm install
-
name: Build project
run: npm run build
- uses: actions/setup-node@v4
with:
node-version: '16.x'
registry-url: 'https://registry.npmjs.org'
- name: Publish project
run: npm publish --provenance --access public
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}