From 94b50c5d4d299583184a498e36a490c7b450dd37 Mon Sep 17 00:00:00 2001 From: NodeByte Date: Mon, 11 May 2026 14:16:35 -0600 Subject: [PATCH] Refactor npm-release workflow to use pnpm correctly --- .github/workflows/npm-release.yml | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/.github/workflows/npm-release.yml b/.github/workflows/npm-release.yml index 9c7daeb..dffb9c9 100644 --- a/.github/workflows/npm-release.yml +++ b/.github/workflows/npm-release.yml @@ -26,23 +26,27 @@ jobs: - name: Checkout repository uses: actions/checkout@v5 + # 1. Install pnpm FIRST + - name: Set up pnpm + uses: pnpm/action-setup@v4 + with: + version: 9.0.0 + + # 2. Set up Node SECOND (Now it can find the pnpm executable for caching) - name: Set up Node.js 20.x uses: actions/setup-node@v4 with: node-version: 20.x registry-url: "https://registry.npmjs.org" cache: pnpm + # Ensure this path is correct relative to the repo root cache-dependency-path: pnpm-lock.yaml - - name: Set up pnpm - uses: pnpm/action-setup@v4 - with: - version: 9.0.0 - + # 3. Only install dependencies required for the SDK - name: Install dependencies - run: pnpm install --frozen-lockfile + run: pnpm install --filter "./packages/sdk..." --frozen-lockfile - - name: Publish package + - name: Publish SDK working-directory: packages/sdk run: | pnpm run build