From 2b98ad3b7870c8b6caa9bd5da4d15db5e44d3a6c Mon Sep 17 00:00:00 2001 From: Malcolm Nixon Date: Mon, 7 Sep 2026 15:04:06 -0400 Subject: [PATCH] Fix MSI version display bugs - Add ARPDISPLAYVERSION property set to the full semver (MsiPackageVersion) so Windows Add/Remove Programs shows e.g. '0.1.0-beta.1' instead of the ICE24-stripped numeric-only ProductVersion ('0.1.0'). - Pass -p:Version=$(MsiPackageVersion) to the isolated nested 'dotnet publish' Exec command in the wixproj so the exe embedded in the MSI is actually stamped with the release version instead of falling back to the csproj's hardcoded default (0.0.0). - Expose MsiPackageVersion as a WiX preprocessor variable alongside ProductVersion via DefineConstants. Verified locally: built the MSI with ProductVersion=0.1.0 and MsiPackageVersion=0.1.0-beta.1, confirmed the embedded exe reports ProductVersion 0.1.0-beta.1+ and the MSI's ARPDISPLAYVERSION property is 0.1.0-beta.1. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- .../DemaConsulting.AgentControl.Msi.wixproj | 8 ++++++-- src/DemaConsulting.AgentControl.Msi/Package.wxs | 9 +++++++++ 2 files changed, 15 insertions(+), 2 deletions(-) diff --git a/src/DemaConsulting.AgentControl.Msi/DemaConsulting.AgentControl.Msi.wixproj b/src/DemaConsulting.AgentControl.Msi/DemaConsulting.AgentControl.Msi.wixproj index 5774af6..7bc00a3 100644 --- a/src/DemaConsulting.AgentControl.Msi/DemaConsulting.AgentControl.Msi.wixproj +++ b/src/DemaConsulting.AgentControl.Msi/DemaConsulting.AgentControl.Msi.wixproj @@ -22,7 +22,6 @@ true x64 0.0.0 - ProductVersion=$(ProductVersion) $(ProductVersion) AgentControl-$(MsiPackageVersion) + + ProductVersion=$(ProductVersion);MsiPackageVersion=$(MsiPackageVersion) @@ -107,7 +111,7 @@ (an even count, which argv parsing resolves to one literal backslash plus a real, unescaped closing quote) so BaseIntermediateOutputPath/BaseOutputPath still end in a proper path separator for the SDK's own path concatenation. --> - + + +