From a669a94e0968386eacedddac30031e14c8204ae3 Mon Sep 17 00:00:00 2001 From: Lenz Weber-Tronic Date: Sat, 29 Jul 2023 17:48:42 +0200 Subject: [PATCH] add "publish" workflow --- .github/workflows/publish.yaml | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 .github/workflows/publish.yaml diff --git a/.github/workflows/publish.yaml b/.github/workflows/publish.yaml new file mode 100644 index 000000000..994956277 --- /dev/null +++ b/.github/workflows/publish.yaml @@ -0,0 +1,24 @@ +name: Publish Package to npmjs +on: + # keeping it purely manual for now as to not accidentally trigger a release + #release: + # types: [published] + workflow_dispatch: +jobs: + publish: + runs-on: ubuntu-latest + permissions: + id-token: write + contents: read + steps: + - uses: actions/checkout@v3 + - uses: actions/setup-node@v3 + with: + node-version: '18.x' + registry-url: 'https://registry.npmjs.org' + cache: 'yarn' + - run: yarn install --frozen-lockfile + - run: yarn test + - run: npm publish --access public --provenance + env: + NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} \ No newline at end of file