Skip to content

Commit d46e176

Browse files
Fix MSI x64 installer and standalone package
1 parent 800a2e9 commit d46e176

File tree

4 files changed

+31
-21
lines changed

4 files changed

+31
-21
lines changed

Build.ps1

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ if ($Setup) {
4646
Write-Host "Building installer..." -ForegroundColor Yellow
4747

4848
# Build WiX installer
49-
msbuild ScriptProSetup\ScriptProSetup.wixproj /p:Configuration=$Config /v:minimal
49+
msbuild ScriptProSetup\ScriptProSetup.wixproj /p:Configuration=$Config /p:Platform=x64 /v:minimal
5050

5151
if ($LASTEXITCODE -ne 0) {
5252
Write-Host "Installer build failed!" -ForegroundColor Red
@@ -79,15 +79,21 @@ if ($Standalone) {
7979
# Copy binaries
8080
Copy-Item "$OutputPath\*" $StandaloneDir -Recurse -Force
8181

82-
# Copy help file
83-
Copy-Item "Modern.Help.html" $StandaloneDir -Force
82+
# Copy README.md from root
83+
if (Test-Path "README.md") {
84+
Copy-Item "README.md" $StandaloneDir -Force
85+
}
8486

8587
Write-Host "Standalone package created: $StandaloneDir" -ForegroundColor Green
8688

8789
# Create ZIP
88-
$ZipPath = "Standalone\ScriptPro-Portable.zip"
90+
$ZipPath = "Release\ScriptPro-Portable.zip"
8991
if (Test-Path $ZipPath) { Remove-Item $ZipPath -Force }
90-
Compress-Archive -Path $StandaloneDir -DestinationPath $ZipPath
92+
93+
# Create Release folder if needed
94+
if (!(Test-Path "Release")) { New-Item -ItemType Directory -Path "Release" | Out-Null }
95+
96+
Compress-Archive -Path "$StandaloneDir\*" -DestinationPath $ZipPath
9197

9298
Write-Host "ZIP created: $ZipPath" -ForegroundColor Green
9399
}

ScriptProSetup/Product.wxs

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,23 +20,30 @@
2020
<File Id="file_ScriptUI_exe" Source="$(var.SolutionDir)\Binaries\x64\$(var.Configuration)\net8.0-windows\ScriptUI.exe" KeyPath="yes" Checksum="yes" />
2121
</Component>
2222
<Component Id="ScriptUI.dll" Guid="E1234567-89AB-CDEF-0123-456789ABCDEF" Bitness="always64">
23-
<File Id="file_ScriptUI_dll" Source="$(var.SolutionDir)\Binaries\x64\$(var.Configuration)\net8.0-windows\ScriptUI.dll" />
23+
<File Id="file_ScriptUI_dll" Source="$(var.SolutionDir)\Binaries\x64\$(var.Configuration)\net8.0-windows\ScriptUI.dll" KeyPath="yes" />
2424
</Component>
2525
<Component Id="DrawingListUC.dll" Guid="7EA07F38-9DE2-4D23-B04C-C447B09A44BE" Bitness="always64">
2626
<File Id="file_DrawingListUC_dll" Source="$(var.SolutionDir)\Binaries\x64\$(var.Configuration)\net8.0-windows\DrawingListUC.dll" KeyPath="yes" />
2727
</Component>
2828

2929
<!-- Configuration Files -->
3030
<Component Id="ConfigFiles" Guid="B1234567-89AB-CDEF-0123-456789ABCDEF" Bitness="always64">
31-
<File Id="file_ScriptUI_runtimeconfig" Source="$(var.SolutionDir)\Binaries\x64\$(var.Configuration)\net8.0-windows\ScriptUI.runtimeconfig.json" />
31+
<File Id="file_ScriptUI_runtimeconfig" Source="$(var.SolutionDir)\Binaries\x64\$(var.Configuration)\net8.0-windows\ScriptUI.runtimeconfig.json" KeyPath="yes" />
3232
<File Id="file_ScriptUI_deps" Source="$(var.SolutionDir)\Binaries\x64\$(var.Configuration)\net8.0-windows\ScriptUI.deps.json" />
3333
<File Id="file_ScriptUI_config" Source="$(var.SolutionDir)\Binaries\x64\$(var.Configuration)\net8.0-windows\ScriptUI.dll.config" />
3434
<File Id="file_DrawingListUC_config" Source="$(var.SolutionDir)\Binaries\x64\$(var.Configuration)\net8.0-windows\DrawingListUC.dll.config" />
3535
</Component>
3636

3737
<!-- Help Files -->
3838
<Component Id="HelpFiles" Guid="C1234567-89AB-CDEF-0123-456789ABCDEF" Bitness="always64">
39-
<File Id="file_Modern_Help_html" Source="$(var.SolutionDir)\Binaries\x64\$(var.Configuration)\net8.0-windows\Modern.Help.html" />
39+
<File Id="file_Modern_Help_html" Source="$(var.SolutionDir)\Binaries\x64\$(var.Configuration)\net8.0-windows\Modern.Help.html" KeyPath="yes" />
40+
<File Id="file_README_md" Source="$(var.SolutionDir)\README.md" />
41+
</Component>
42+
43+
<!-- Runtime Dependencies -->
44+
<Component Id="RuntimeDependencies" Guid="D1234567-89AB-CDEF-0123-456789ABCDEF" Bitness="always64">
45+
<File Id="file_System_CodeDom_dll" Source="$(var.SolutionDir)\Binaries\x64\$(var.Configuration)\net8.0-windows\System.CodeDom.dll" KeyPath="yes" />
46+
<File Id="file_System_Management_dll" Source="$(var.SolutionDir)\Binaries\x64\$(var.Configuration)\net8.0-windows\System.Management.dll" />
4047
</Component>
4148
</DirectoryRef>
4249

@@ -115,6 +122,7 @@
115122
<ComponentRef Id="DrawingListUC.dll" />
116123
<ComponentRef Id="ConfigFiles" />
117124
<ComponentRef Id="HelpFiles" />
125+
<ComponentRef Id="RuntimeDependencies" />
118126
<!-- Images folder components will be auto-included via ComponentGroup from Heat -->
119127
<ComponentGroupRef Id="ImagesComponentGroup" />
120128
<!-- Step 3: Tell WiX to install the shortcut -->

ScriptUI/Properties/Settings.Designer.cs

Lines changed: 9 additions & 12 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

ScriptUI/Properties/launchSettings.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
"profiles": {
33
"ScriptUI": {
44
"commandName": "Project",
5-
"commandLineArgs": "\"D:\\Projects\\2025\\ScriptProPlus\\TestFiles\\xyz.bpl\" run exit",
65
"workingDirectory": "D:\\Projects\\2025\\ScriptProPlus"
76
}
87
}

0 commit comments

Comments
 (0)