From 4202da10c6e5a0ce6e3a6773ad6cbe3fb4523de4 Mon Sep 17 00:00:00 2001 From: nullsoepic Date: Tue, 24 Sep 2024 16:54:09 +0200 Subject: [PATCH] fix publish action --- .github/workflows/publish.yml | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index dd22995..71dd83d 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -6,7 +6,7 @@ on: - main jobs: - test-and-publish: + publish: runs-on: ubuntu-latest steps: @@ -28,9 +28,6 @@ jobs: run: bun run prepublishOnly - name: Publish to npm - if: github.event_name == 'push' && github.ref == 'refs/heads/main' - run: | - echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_TOKEN }}" > ~/.npmrc - npm publish - env: - NPM_TOKEN: ${{ secrets.NPM_TOKEN }} + uses: JS-DevTools/npm-publish@v3.1.1 + with: + token: ${{ secrets.NPM_TOKEN }}