electron-builder icon indicating copy to clipboard operation
electron-builder copied to clipboard

Question: Electron/Electron Builder get info about binary

Open jrohlandt opened this issue 5 months ago • 2 comments

We are distributing our Electron app for Macs using Intel and also Apple Silicon. We are using electron-builder --mac --x64 --arm64 to create an Intel and ARM version.

I need a way to know if a user on Apple Silicon has accidentally installed the Intel version of the app. Currently I'm able to get the platform and architecture of the system. But how can I get the architecture that the .dmg file was built for? I thought "process.target_arch" would be it but it is always undefined.

Electron: ${process.versions["electron"]} Node: ${process.versions["node"]} Chromium: ${process.versions["chrome"]} Platform: ${os.platform} Architecture: ${os.arch} Target Arch: ${process?.target_arch} OS Version: ${process.getSystemVersion()}

jrohlandt avatar Sep 18 '24 14:09 jrohlandt