From d1714a86c7a02c0c52fbd28226027a2e4ae50c21 Mon Sep 17 00:00:00 2001 From: benya Date: Sun, 15 Feb 2026 22:04:54 +0300 Subject: [PATCH] fix(ci): avoid non-zero exit from iscc help probe - stop calling iscc /? in Ensure Inno Setup step - resolve compiler path via Get-Command/Test-Path and finish with exit 0 --- .gitea/workflows/release.yml | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/.gitea/workflows/release.yml b/.gitea/workflows/release.yml index 871cb7c..ed6e818 100644 --- a/.gitea/workflows/release.yml +++ b/.gitea/workflows/release.yml @@ -41,20 +41,24 @@ jobs: - name: Ensure Inno Setup 6 shell: powershell run: | - if (Get-Command iscc.exe -ErrorAction SilentlyContinue) { - iscc.exe /? | Out-Null + $isccPath = "" + $inPath = Get-Command iscc.exe -ErrorAction SilentlyContinue + if ($inPath) { + $isccPath = $inPath.Source Write-Host "Inno Setup compiler found in PATH." } elseif (Test-Path "C:\Program Files (x86)\Inno Setup 6\ISCC.exe") { "C:\Program Files (x86)\Inno Setup 6" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append - & "C:\Program Files (x86)\Inno Setup 6\ISCC.exe" /? | Out-Null + $isccPath = "C:\Program Files (x86)\Inno Setup 6\ISCC.exe" Write-Host "Inno Setup compiler found in Program Files (x86)." } elseif (Test-Path "C:\Program Files\Inno Setup 6\ISCC.exe") { "C:\Program Files\Inno Setup 6" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append - & "C:\Program Files\Inno Setup 6\ISCC.exe" /? | Out-Null + $isccPath = "C:\Program Files\Inno Setup 6\ISCC.exe" Write-Host "Inno Setup compiler found in Program Files." } else { throw "Inno Setup 6 is not installed on runner. Install Inno Setup and restart runner service." } + Write-Host "Using ISCC: $isccPath" + exit 0 - name: Extract app version id: extract_version