Squirrel / Squirrel.Windows

An installation and update framework for Windows desktop apps
MIT License
7.23k stars 1.02k forks source link

MSI install: No autostart after install #1769

Open siimv opened 2 years ago

siimv commented 2 years ago

This is related to #1311 as I didn't see the correct solution (besides forking repository and making own changes).

Basically, when application is installed through MSI deployment tool when the user logs in the first time, then application is not started automatically (it works, when user logs in and out again).

I believe this is the code causing it: https://github.com/Squirrel/Squirrel.Windows/blob/136db8c5d671ce1823470fedeefe9571a8e1f399/src/Setup/winmain.cpp#L56-L64

And it gets called from the MSI: https://github.com/Squirrel/Squirrel.Windows/blob/136db8c5d671ce1823470fedeefe9571a8e1f399/vendor/wix/template.wxs#L26-L32

It would make sense to enable auto-start behaviour for this scenario, as the whole point of the MSI is to automate things from the IT perspective. Maybe we could add some argument (like --msi-not-silent) to the releasify command to enable this behavior and to not brake current behavior?