summaryrefslogtreecommitdiff
path: root/.github/workflows/release-windows.yml
diff options
context:
space:
mode:
authorhaoyuren <13851610112@163.com>2026-07-30 09:08:42 +0800
committerhaoyuren <13851610112@163.com>2026-07-30 09:08:42 +0800
commit6026c4191cfdaadd379565cfc064158d619f2fbc (patch)
treed8f31e56940dc90e564408bc7485e2adff055239 /.github/workflows/release-windows.yml
parente1a48bcf4b554d8a4f3d2cfa73df69c548cdde8b (diff)
Pin node-gyp ^11 via overrides for VS2022 detection on Windows CI
@electron/rebuild requires the in-tree node-gyp directly, so the npm_config_node_gyp env override had no effect — force the resolution tree-wide instead. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Diffstat (limited to '.github/workflows/release-windows.yml')
-rw-r--r--.github/workflows/release-windows.yml12
1 files changed, 3 insertions, 9 deletions
diff --git a/.github/workflows/release-windows.yml b/.github/workflows/release-windows.yml
index a458265..3c0ee00 100644
--- a/.github/workflows/release-windows.yml
+++ b/.github/workflows/release-windows.yml
@@ -22,15 +22,9 @@ jobs:
with:
node-version: 20
- # The node-gyp version pulled in by the dependency tree (v9) cannot
- # detect Visual Studio 2022 on current runner images — point npm at
- # the latest node-gyp for the node-pty native rebuild.
- - name: Use latest node-gyp (VS2022 detection)
- shell: pwsh
- run: |
- npm install -g node-gyp@latest
- "npm_config_node_gyp=$(npm root -g)\node-gyp\bin\node-gyp.js" | Out-File -FilePath $env:GITHUB_ENV -Append -Encoding utf8
-
+ # node-gyp is pinned to ^11 via package.json "overrides" — the v9 the
+ # tree would otherwise hoist cannot detect VS2022 on current runners
+ # (and @electron/rebuild requires the in-tree node-gyp directly).
- name: Install dependencies
run: npm ci