@@ -212,6 +212,7 @@ jobs:
212212 "arm" { "arm" }
213213 default { "x64" }
214214 }
215+ $programFilesDirId = if ($archLabel -eq "x86") { "ProgramFilesFolder" } else { "ProgramFiles64Folder" }
215216
216217 New-Item -ItemType Directory -Force -Path installer | Out-Null
217218 New-Item -ItemType Directory -Force -Path release_assets | Out-Null
@@ -228,7 +229,6 @@ jobs:
228229 ' <Property Id="ARPCONTACT" Value="TamKungZ_" />',
229230 ' <Property Id="ARPURLINFOABOUT" Value="https://github.com" />',
230231 ' <Property Id="ARPHELPLINK" Value="https://github.com" />',
231- ' <Property Id="ARPINSTALLLOCATION" Value="[INSTALLFOLDER]" />',
232232 (' <Icon Id="AppIcon.ico" SourceFile="{0}" />' -f $iconPath),
233233 ' <Property Id="ARPPRODUCTICON" Value="AppIcon.ico" />',
234234 ' <Property Id="WIXUI_INSTALLDIR" Value="INSTALLFOLDER" />',
@@ -241,7 +241,7 @@ jobs:
241241 '',
242242 ' <Fragment>',
243243 ' <Directory Id="TARGETDIR" Name="SourceDir">',
244- ' <Directory Id="ProgramFilesFolder ">',
244+ ( ' <Directory Id="{0} ">' -f $programFilesDirId) ,
245245 ' <Directory Id="INSTALLFOLDER" Name="ImageMerge" />',
246246 ' </Directory>',
247247 ' <Directory Id="ProgramMenuFolder">',
@@ -256,11 +256,11 @@ jobs:
256256 ' <Component Id="StartMenuShortcutComponent" Directory="ImageMergeProgramMenuFolder" Guid="*">',
257257 ' <Shortcut Id="StartMenuShortcut" Name="ImageMerge" Description="ImageMerge" Target="[INSTALLFOLDER]ImageMerge.exe" WorkingDirectory="INSTALLFOLDER" />',
258258 ' <RemoveFolder Id="RemoveImageMergeProgramMenuFolder" On="uninstall" />',
259- ' <RegistryValue Root="HKCU" Key="Software\\ TamKungZ_\ \ImageMerge" Name="StartMenuShortcut" Type="integer" Value="1" KeyPath="yes" />',
259+ ' <RegistryValue Root="HKCU" Key="Software\TamKungZ_\ImageMerge" Name="StartMenuShortcut" Type="integer" Value="1" KeyPath="yes" />',
260260 ' </Component>',
261261 ' <Component Id="DesktopShortcutComponent" Directory="DesktopFolder" Guid="*">',
262262 ' <Shortcut Id="DesktopShortcut" Name="ImageMerge" Description="ImageMerge" Target="[INSTALLFOLDER]ImageMerge.exe" WorkingDirectory="INSTALLFOLDER" />',
263- ' <RegistryValue Root="HKCU" Key="Software\\ TamKungZ_\ \ImageMerge" Name="DesktopShortcut" Type="integer" Value="1" KeyPath="yes" />',
263+ ' <RegistryValue Root="HKCU" Key="Software\TamKungZ_\ImageMerge" Name="DesktopShortcut" Type="integer" Value="1" KeyPath="yes" />',
264264 ' </Component>',
265265 ' </ComponentGroup>',
266266 ' </Fragment>',
0 commit comments