Skip to content

Commit b7746c9

Browse files
authored
CI: fix NSIS installer (#1189)
2 parents e9aa312 + e8dba50 commit b7746c9

File tree

1 file changed

+15
-1
lines changed

1 file changed

+15
-1
lines changed

.github/workflows/CI.yml

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ jobs:
6262

6363
- name: Setup Fortran compiler
6464
uses: fortran-lang/[email protected]
65-
id: setup-fortran
65+
id: setup-fortran
6666
with:
6767
compiler: ${{ matrix.toolchain.compiler }}
6868
version: ${{ matrix.toolchain.version }}
@@ -264,6 +264,20 @@ jobs:
264264
env:
265265
envar_download: "https://github.com/GsNSIS/EnVar/releases/download/v0.3.1/EnVar-Plugin.zip"
266266

267+
- name: Install NSIS
268+
run: choco install nsis -y
269+
shell: pwsh
270+
271+
- name: Add NSIS to PATH
272+
shell: pwsh
273+
run: |
274+
$dirs = @(
275+
"${env:ProgramFiles(x86)}\NSIS",
276+
"${env:ProgramFiles}\NSIS"
277+
) | Where-Object { $_ -and (Test-Path $_) }
278+
if (-not $dirs) { throw "NSIS not found under Program Files." }
279+
$dirs | ForEach-Object { $_ | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append }
280+
267281
- name: Generate installer
268282
run: |
269283
cd ./ci

0 commit comments

Comments
 (0)