mongodb-js / electron-squirrel-startup

Default Squirrel.Windows event handler for your Electron apps.
Apache License 2.0
217 stars 41 forks source link

Updates not installed when starting Electron app via custom protocol link #32

Open dsteegen opened 7 years ago

dsteegen commented 7 years ago

Hi,

How can I force the application to start looking for updates/install updates when it is being started with a custom protocol link? At this moment it only works when directly opening the application via the .exe.

The code for installing the updates is behind the typical if check that is suggested in the readme:

if (!require('electron-squirrel-startup')) {

}

But it seems that the squirrel events for triggering the install will not be set in the first argument of process.argv

Is there a work around available for this problem? The reason why custom protocol links are being used is because we have different shorts cuts for the Electron app that points to different environments (e.g dev/test/acc/prod). When not using the exe directly, it will redirect the user to the prod environment.