From 5e110986a8c5890156ed82d96f946bc41fef5aa4 Mon Sep 17 00:00:00 2001 From: Tim Kleyersburg Date: Fri, 10 Sep 2021 11:38:56 +0200 Subject: [PATCH] feat: publish new npm package upon release --- .github/workflows/npm.yaml | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 .github/workflows/npm.yaml diff --git a/.github/workflows/npm.yaml b/.github/workflows/npm.yaml new file mode 100644 index 0000000..c37eba0 --- /dev/null +++ b/.github/workflows/npm.yaml @@ -0,0 +1,18 @@ +name: Node.js Package +on: + release: + types: [ created ] +jobs: + build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + # Setup .npmrc file to publish to npm + - uses: actions/setup-node@v2 + with: + node-version: '12.x' + registry-url: 'https://registry.npmjs.org' + - run: npm install + - run: npm publish + env: + NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} \ No newline at end of file