From 03220c3041f1c65b9ee4be8d85bdbd741466cfb8 Mon Sep 17 00:00:00 2001 From: Tanner Van De Walle Date: Fri, 4 Sep 2026 13:41:31 -0700 Subject: [PATCH] CI: restore generated SLN or SLNX --- .github/workflows/prBuild.yml | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/.github/workflows/prBuild.yml b/.github/workflows/prBuild.yml index 5966cdc..652eb29 100644 --- a/.github/workflows/prBuild.yml +++ b/.github/workflows/prBuild.yml @@ -21,7 +21,18 @@ jobs: run: cmake -B ${{github.workspace}}/build -DUSE_PIX=OFF -DCMAKE_SYSTEM_VERSION="10.0.22621.0" - name: Nuget Restore - run: nuget restore ${{github.workspace}}/build/d3d12translationlayer.sln + shell: pwsh + run: | + $solutions = @( + Get-ChildItem "${{ github.workspace }}/build" -File | + Where-Object { $_.Extension -in '.sln', '.slnx' } + ) + + if ($solutions.Count -ne 1) { + throw "Expected exactly one generated solution, found $($solutions.Count): $($solutions.FullName -join ', ')" + } + + nuget restore $solutions[0].FullName - name: Build run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}}