File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -237,9 +237,30 @@ jobs:
237237 exit 1
238238 }
239239
240+ # Find makensis - choco installs to Program Files
241+ $nsisPath = "C:\Program Files (x86)\NSIS\makensis.exe"
242+ if (!(Test-Path $nsisPath)) {
243+ $nsisPath = "C:\Program Files\NSIS\makensis.exe"
244+ }
245+ if (!(Test-Path $nsisPath)) {
246+ # Try to find it via where command
247+ $nsisPath = (Get-Command makensis -ErrorAction SilentlyContinue).Source
248+ }
249+ if (!$nsisPath -or !(Test-Path $nsisPath)) {
250+ Write-Error "NSIS makensis.exe not found!"
251+ exit 1
252+ }
253+
254+ Write-Host "Using NSIS at: $nsisPath"
255+
240256 # Build NSIS installer
241257 Write-Host "Building NSIS installer..."
242- makensis installer.nsi
258+ & $nsisPath installer.nsi
259+
260+ if ($LASTEXITCODE -ne 0) {
261+ Write-Error "NSIS build failed with exit code $LASTEXITCODE"
262+ exit 1
263+ }
243264
244265 # Verify installer was created
245266 if (Test-Path "dist/NetworkMonitor-Setup-*.exe") {
You can’t perform that action at this time.
0 commit comments