From af73cf5094ec258600042a1dbfd8eebe17b360ad Mon Sep 17 00:00:00 2001 From: Fedor Indutny <79877362+indutny-signal@users.noreply.github.com> Date: Thu, 2 Apr 2026 14:19:10 -0700 Subject: [PATCH] A bit faster pnpm install in CI --- .github/workflows/benchmark.yml | 3 +++ .github/workflows/ci.yml | 30 ++++++++++++++++++++++++++++++ .github/workflows/icu-book.yml | 3 +++ .github/workflows/stories.yml | 3 +++ 4 files changed, 39 insertions(+) diff --git a/.github/workflows/benchmark.yml b/.github/workflows/benchmark.yml index b354648ff9..6c72820a6e 100644 --- a/.github/workflows/benchmark.yml +++ b/.github/workflows/benchmark.yml @@ -105,6 +105,9 @@ jobs: # CXX: sccache g++ # SCCACHE_GHA_ENABLED: "true" NPM_CONFIG_LOGLEVEL: verbose + # We rebuild in `electron:install-app-deps` that doesn't look at this + # environment variable + NPM_CONFIG_NODE_GYP: echo - name: Build typescript run: pnpm run generate diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 4284a549f4..57e9eace80 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -55,6 +55,9 @@ jobs: # CXX: sccache g++ # SCCACHE_GHA_ENABLED: "true" NPM_CONFIG_LOGLEVEL: verbose + # We rebuild in `electron:install-app-deps` that doesn't look at this + # environment variable + NPM_CONFIG_NODE_GYP: echo - run: pnpm run generate - run: pnpm run lint @@ -114,6 +117,9 @@ jobs: # CXX: sccache clang++ # SCCACHE_GHA_ENABLED: "true" NPM_CONFIG_LOGLEVEL: verbose + # We rebuild in `electron:install-app-deps` that doesn't look at this + # environment variable + NPM_CONFIG_NODE_GYP: echo - run: pnpm run prepare-beta-build - run: pnpm run generate - run: pnpm run test-node @@ -188,6 +194,9 @@ jobs: # CXX: sccache g++ # SCCACHE_GHA_ENABLED: "true" NPM_CONFIG_LOGLEVEL: verbose + # We rebuild in `electron:install-app-deps` that doesn't look at this + # environment variable + NPM_CONFIG_NODE_GYP: echo - run: pnpm run prepare-beta-build - run: pnpm run generate @@ -264,10 +273,12 @@ jobs: cache: 'pnpm' cache-dependency-path: 'pnpm-lock.yaml' + - run: touch noop.js - name: Install Desktop node_modules run: pnpm install env: NPM_CONFIG_LOGLEVEL: verbose + NPM_CONFIG_NODE_GYP: ${{ github.workspace }}\noop.js - run: copy package.json temp.json - run: del package.json @@ -406,6 +417,9 @@ jobs: # CXX: sccache g++ # SCCACHE_GHA_ENABLED: "true" NPM_CONFIG_LOGLEVEL: verbose + # We rebuild in `electron:install-app-deps` that doesn't look at this + # environment variable + NPM_CONFIG_NODE_GYP: echo - name: Build typescript run: pnpm run generate @@ -476,9 +490,25 @@ jobs: key: electron-gyp-${{ runner.os }}-${{ hashFiles('pnpm-lock.yaml') }} - name: Install Desktop node_modules + if: matrix.os != 'windows-latest-8-cores' run: pnpm install env: NPM_CONFIG_LOGLEVEL: verbose + # We rebuild in `electron:install-app-deps` that doesn't look at this + # environment variable + NPM_CONFIG_NODE_GYP: echo + + - run: touch noop.js + if: matrix.os == 'windows-latest-8-cores' + + - name: Install Desktop node_modules on Windows + if: matrix.os == 'windows-latest-8-cores' + run: pnpm install + env: + NPM_CONFIG_LOGLEVEL: verbose + # We rebuild in `electron:install-app-deps` that doesn't look at this + # environment variable + NPM_CONFIG_NODE_GYP: ${{ github.workspace }}\noop.js - run: pnpm generate:phase-0 - name: Run OS version check diff --git a/.github/workflows/icu-book.yml b/.github/workflows/icu-book.yml index 7cbd74505a..aad8cb4e55 100644 --- a/.github/workflows/icu-book.yml +++ b/.github/workflows/icu-book.yml @@ -44,6 +44,9 @@ jobs: # CXX: sccache g++ # SCCACHE_GHA_ENABLED: "true" NPM_CONFIG_LOGLEVEL: verbose + # We rebuild in `electron:install-app-deps` that doesn't look at this + # environment variable + NPM_CONFIG_NODE_GYP: echo - run: pnpm run build:storybook - run: ./node_modules/.bin/playwright install chromium diff --git a/.github/workflows/stories.yml b/.github/workflows/stories.yml index e4b45d09c1..e3c67f6835 100644 --- a/.github/workflows/stories.yml +++ b/.github/workflows/stories.yml @@ -44,6 +44,9 @@ jobs: # CXX: sccache g++ # SCCACHE_GHA_ENABLED: "true" NPM_CONFIG_LOGLEVEL: verbose + # We rebuild in `electron:install-app-deps` that doesn't look at this + # environment variable + NPM_CONFIG_NODE_GYP: echo - run: pnpm run build:storybook - run: ./node_modules/.bin/playwright install chromium