fix(bundler): swap WIX registry search order to prioritize InstallDir#14945
Conversation
I couldn't remember my comment over there at all anymore 😂 |
Package Changes Through 1356a35There are 3 changes which include tauri-cli with patch, @tauri-apps/cli with patch, tauri-bundler with patch Planned Package VersionsThe following package releases are the planned based on the context of changes in this pull request.
Add another change file through the GitHub UI by following this link. Read about change files or the docs at github.com/jbolda/covector |
|
Thanks for the PR! Would you mind signing (and force-pushing) your commit? Our branch protection rules require that :) |
|
Perhaps a small comment in the wix file that explains why the order is like it is would be nice too i think so we don't end up swapping it again 😅 |
|
Added a NOTE comment above the RegistrySearch block explaining that in WIX the last successful match wins, so the ordering is intentional. Should help prevent future accidental swaps. Regarding commit signing — I'll get that sorted and force-push the signed commits shortly. |
ae4d190 to
6734788
Compare
When both the NSIS default key and the named InstallDir key exist in the registry, WIX uses the last RegistrySearch value found. The previous order caused the NSIS default key to override InstallDir, which made apps installed to Program Files move to AppData on update. Swap the order so InstallDir (set by the MSI installer) is searched last and takes priority. Closes tauri-apps#14213
Adds a NOTE comment above the RegistrySearch block to clarify that the last successful match wins in WIX, preventing future accidental reordering.
6734788 to
57a45b9
Compare
|
Commits are now signed and force-pushed. Also added the NOTE comment you suggested about the registry search ordering. |
|
Awesome, thanks! |
Fixes #14213
When both the NSIS default registry key and the named
InstallDirkey exist (e.g. after migrating from NSIS to WIX), the WIX installer was using the wrong install path on update. This happened because WIX evaluates multipleRegistrySearchentries within aPropertyand uses the last value found.The previous order searched for
InstallDirfirst and the NSIS default key second, so the default key would win when both existed. This caused apps installed toC:\Program Filesto silently move to the AppData folder on update via the updater plugin.This swaps the order so the NSIS default key is searched first (as a fallback), and the named
InstallDirkey is searched second, giving it priority when present.As @FabianLars noted in the issue thread, swapping the two searches is the correct approach.