build(deps-dev): apply updates
[poolifier.git] / .github / workflows / npmpublish.yml
index e32ce385eeb62d08f0d8bc2bee7deed7c9e130c2..d124eed3c81052a29f4898ba4d5894d488ca4f70 100644 (file)
@@ -18,20 +18,23 @@ jobs:
           node-version: '18.x'
 
       - name: Install
-        run: npm ci
+        run: |
+          corepack enable
+          corepack prepare pnpm@latest --activate
+          pnpm install
 
       - name: Tests & Coverage
         run: |
-          npm run test
-          npm run coverage
+          pnpm run test
+          pnpm run coverage
 
       - name: Lint
-        run: npm run lint
+        run: pnpm run lint
 
       - name: Production Build
-        run: npm run build:prod
+        run: pnpm run build:prod
 
-  publish-npm:
+  publish:
     needs: build
     runs-on: ubuntu-latest
 
@@ -50,16 +53,25 @@ jobs:
         uses: jaywcjlove/github-action-package@main
 
       - name: Install
-        run: npm ci
+        run: |
+          corepack enable
+          corepack prepare pnpm@latest --activate
+          pnpm install
 
       - name: Publish Release
         if: ${{ contains(steps.package-version.outputs.version, '-') == false }}
-        run: npm publish
+        run: pnpm publish --no-git-checks
         env:
           NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
 
-      - name: Publish Beta
-        if: ${{ contains(steps.package-version.outputs.version, 'beta') }}
-        run: npm publish --tag beta
+      - name: Publish Pre-Release
+        if: ${{ contains(steps.package-version.outputs.version, '-') == true }}
+        run: pnpm publish --no-git-checks --tag next
         env:
           NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
+
+      # - name: Publish Beta Release
+      #   if: ${{ contains(steps.package-version.outputs.version, '-beta') == true }}
+      #   run: pnpm publish --no-git-checks --tag beta
+      #   env:
+      #     NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}