From d830e4e4fbe1af4a4b42b4f62db841c075491eb1 Mon Sep 17 00:00:00 2001 From: simonireilly Date: Thu, 9 Jun 2022 20:37:33 +0100 Subject: [PATCH] Install pacakges before publishing --- .github/workflows/npm-publish.yml | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 .github/workflows/npm-publish.yml diff --git a/.github/workflows/npm-publish.yml b/.github/workflows/npm-publish.yml new file mode 100644 index 0000000..23c8a6f --- /dev/null +++ b/.github/workflows/npm-publish.yml @@ -0,0 +1,25 @@ +name: Node.js Package + +on: + release: + types: [created] + +jobs: + publish-npm: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + + - uses: actions/setup-node@v3 + with: + node-version: 16 + registry-url: https://registry.npmjs.org/ + cache: "yarn" + + - run: yarn + + - run: yarn build + + - run: npm publish --tag beta + env: + NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}