Skip to content
Discussion options

You must be logged in to vote

That error comes from electron-builder, not electron-vite: before it builds the NSIS installer it downloads the NSIS binaries from the electron-builder-binaries releases on github.com, and your network can't resolve github.com. Point it at a mirror by setting ELECTRON_BUILDER_BINARIES_MIRROR before you build, for example in PowerShell:

$env:ELECTRON_BUILDER_BINARIES_MIRROR = "https://npmmirror.com/mirrors/electron-builder-binaries/"
pnpm build:win

To make it permanent, run setx ELECTRON_BUILDER_BINARIES_MIRROR https://npmmirror.com/mirrors/electron-builder-binaries/ once and open a new terminal. Putting electron_builder_binaries_mirror=... in .npmrc only works with npm, because pnpm 11 do…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@xing403
Comment options

Answer selected by alex8088
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants