Fix NPM build #2
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: "Publish bundle to npmjs.com" | |
on: | |
push: | |
tags: | |
- "v[0-9]+.[0-9]+.[0-9]+*" | |
jobs: | |
test: | |
uses: "./.github/workflows/test.yml" | |
publish-to-npmjs: | |
name: "Publish to npmjs.com" | |
needs: | |
- "test" | |
runs-on: "ubuntu-latest" | |
steps: | |
- name: "Check out repository" | |
uses: "actions/checkout@v3" | |
- name: "Setup NodeJS" | |
uses: "actions/setup-node@v3" | |
with: | |
node-version: "18.x" | |
- name: "Install dependencies" | |
run: "npm install" | |
- name: "Build" | |
run: "npm run build" | |
- name: "Publish to npmjs.com" | |
run: | | |
echo "//registry.npmjs.org/:_authToken=${NPM_DEPLOY_TOKEN}" > .npmrc | |
npm publish --access public |