fix: check for semantic version#190
Conversation
Signed-off-by: Grigorii K. Shartsev <me@shgk.me>
|
This works for me. Please merge @felixrieseberg - Ty! |
|
Did some testing. On initial installation this seems to work fine, when updating to another version, it wont. E.g. fromn 1.2.3+1 to 1.2.3+2 the stub won't launch, even when built with @ShGKme changes. |
|
I'll have a look at update |
|
Just sharing my thoughts... We build for Intune, with version of If we update with version I think this would be an issue within Squirrel.Msi ? |
|
@ShGKme I created a fork of your patch at https://github.com/MLDMoritz/electron-wix-msi/tree/fix/semantic-version with the new StubExecutable from https://github.com/MLDMoritz/Squirrel.Msi When multiple versions with the same major.minor.patch but different build numbers (e.g., 1.2.3+4 and 1.2.3+5) are installed, ensure the stub executable launches the correct version by comparing build metadata numbers. This fix enhances FindLatestAppDir() to:
Resolves issue where stub can't distinguish between versions that differ only by build number. |
|
I have merged the Squirrel.MSI change |
StubExecutable expects app's version to be a valid semantic version
However,
electron-wix-msisuccessfully creates a package with an invalid semantic version, e.g., Windows version1.2.3.4. The created packages then cannot be launched from the created shortcut or Stub Executable.This PR adds a check for
versionto be a valid semantic version and to prevent successful creation of an invalid package.To make the change less destructive, it tries to transform a Windows version into a semantic one in the most probable case:
1.2.3.4 -> 1.2.3+4