Create .npmrc in dist/electron/UnPackaged even if the project doesn't have one #17504
Labels
bug/2-confirmed
We have reproduce the problem and confirmed that this is a bug.
flavour/quasar-cli-vite
flavour/quasar-cli-webpack
kind/bug 🐞
mode/electron
Qv2 🔝
Quasar v2 issues
We check if
.npmrc
exists before copying it here:quasar/app-vite/lib/modes/electron/electron-builder.js
Lines 86 to 104 in c310cb8
If it doesn't exist, for example, when
.npmrc
is in the root folder in a monorepo, it won't be copied. So, pnpm would use symlinks and the build would fail on Windows, for example.It won't be respected in monorepos without passing
--ignore-workspace
to unpackaged install params, but it's needed for that scenario, it's complex.Solution
So, we should create a
.npmrc
file with the relevant options indist/electron/UnPackaged
even if the project doesn't have a.npmrc
file.Workaround
Create an empty
.npmrc
file in the project folder.The text was updated successfully, but these errors were encountered: