Skip to content

ci: override MSI wix.version for pre-release tags#27

Merged
Nic-dorman merged 1 commit intomainfrom
ci/msi-prerelease-version
Apr 16, 2026
Merged

ci: override MSI wix.version for pre-release tags#27
Nic-dorman merged 1 commit intomainfrom
ci/msi-prerelease-version

Conversation

@Nic-dorman
Copy link
Copy Markdown
Contributor

Summary

Tauri's MSI bundler rejects non-numeric pre-release identifiers, which blocked the v0.6.5-rc.1 release workflow run (mac + linux built fine, but Windows MSI errored with "optional pre-release identifier in app version must be numeric-only"). With Windows failing, `compose-latest-json` (which needs: build-windows) never ran, so PR #23's release-workflow fix was not actually validated.

Fix

Compute `wix.version` at build time by stripping the pre-release suffix from `tauri.conf.json`'s version — `0.6.5-rc.1` → `0.6.5` for MSI metadata only. Passed into `tauri build` via the same `--config` override that already sets `signCommand`.

  • Override is Windows-only (MSI inherits the 4-part numeric PE resource version, a Windows constraint).
  • App's embedded semver is untouched — `env!("CARGO_PKG_VERSION")`, the updater comparator, and mac/linux bundle versions all still see `0.6.5-rc.1`.
  • Only affects what Windows' Add/Remove Programs displays.

After this merges

  1. Delete the failed draft release and the `v0.6.5-rc.1` tag.
  2. Re-push the tag to re-run the release workflow.
  3. Inspect the produced `latest.json` against PR ci: fix latest.json generation in release workflow #23's integrity assertions (no `VERSION`, no `/releases/download/untagged-`, 9 platform entries).

🤖 Generated with Claude Code

Tauri's MSI bundler errors on non-numeric pre-release identifiers:
```
failed to bundle project `optional pre-release identifier in app version
must be numeric-only and cannot be greater than 65535 for msi target`
```

This blocks v0.6.5-rc.1 (and any `-rc.N` / `-beta.N` / `-alpha.N` tag)
from producing the Windows MSI, which in turn skips compose-latest-json
(it needs: build-windows), leaving the release workflow fix from PR #23
unvalidated.

The constraint is Windows-specific (MSI inherits the 4-part numeric PE
resource version). Fix by computing a numeric-only `wix.version` from
tauri.conf.json at build time — strip everything after `-` so `0.6.5-rc.1`
becomes `0.6.5` for MSI metadata only. The app's embedded semver (what
the updater compares, what `env!("CARGO_PKG_VERSION")` returns) stays
untouched, so pre-release tags still behave as pre-releases everywhere
except the Windows installer's Add/Remove Programs display.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@Nic-dorman Nic-dorman force-pushed the ci/msi-prerelease-version branch from a432ad4 to c2198a0 Compare April 16, 2026 19:59
@Nic-dorman Nic-dorman merged commit ae55253 into main Apr 16, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant