automation-stack / node-machine-id

Unique machine (desktop) id (no admin privileges required)
MIT License
584 stars 62 forks source link

Electron and windows #9

Closed danilopinotti closed 7 years ago

danilopinotti commented 7 years ago

Someone has managed to use the node-machine-id within the Electron in Windows? When we do the build, the software does not load, it is blank and does not display any error message.

gfhack commented 7 years ago

I have the same problem, I'm using Ember-Electron. When I install on Windows it doesn't work, both Mac and Linux works.

gfhack commented 7 years ago

err I have this error. The system can't find the Registry Key

automation-stack commented 7 years ago

@wartent what module version you are using? In the last version path to REG util is well-formed %windir%\System32\REG

gfhack commented 7 years ago

I'm using node-machine-id version 1.1.4 It's a Win 8 machine. I'm creating the installer with grunt-electron-installer in a MacOS machine using Node v6.5.0 and Electron 1.4.14. It's not signed/certified, can that be the problem?

thanks for the help 👍

alvarezn commented 7 years ago

Are you using 32-bit electron from a 64-bit Windows installation?

gfhack commented 7 years ago

@alvarezn yes, could that be the problem?

alvarezn commented 7 years ago

What brought me here as well was that this package, on Windows, seems to have 32-bit app on 32-bit OS support, and 64-bit app on 64-bit OS support, but not 32-bit app on 64-bit OS support. So if you use the 64-bit version of electron everything should work for you... assuming that's an option.

Alternately, if the command line to reg.exe is appended with /reg:64 on 64-bit Windows OS, it should fix the problem. It seems this is just grabbing a registry key that Microsoft didn't identify as not being reflected by its 32/64 bit logic and only appears in the 64-bit registry.

gfhack commented 7 years ago

@alvarezn It working, thank you! 👍 @automation-stack thank you for the attention, help and this awesome package! 👍

automation-stack commented 7 years ago

Fixed in 1.1.6 2626bdde516047da16958a5dde5514940766dff2