File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -208,9 +208,22 @@ jobs:
208208 compiler : ${{ matrix.dc }}
209209 - name : Verify toolchain
210210 shell : pwsh
211+ env :
212+ DC_NAME : ${{ matrix.dc }}
211213 run : |
212- dmd --version 2>$null; if ($LASTEXITCODE -ne 0) { "dmd not found"; exit 1 }
213- dub --version; if ($LASTEXITCODE -ne 0) { "dub not found"; exit 1 }
214+ Write-Host "matrix.dc = $env:DC_NAME"
215+ dub --version 2>$null
216+ if ($LASTEXITCODE -ne 0) { "dub not found"; exit 1 }
217+
218+ if ($env:DC_NAME -like "dmd.*") {
219+ dmd --version 2>$null
220+ if ($LASTEXITCODE -ne 0) { "dmd not found"; exit 1 }
221+ } else if ($env:DC_NAME -like "ldc.*") {
222+ ldc2 --version 2>$null
223+ if ($LASTEXITCODE -ne 0) { "dmd not found"; exit 1 }
224+ } else {
225+ throw "Unknown compiler in matrix.dc: '$env:DC_NAME' (expected prefix 'dmd' or 'ldc')"
226+ }
214227 Write-Host "ARCH=$env:ARCH"
215228 Write-Host "Path=$env:Path"
216229 - name : Cache dub packages (safe to share)
You can’t perform that action at this time.
0 commit comments