From ff392f09059896a8aabab667b6931f3247ba978c Mon Sep 17 00:00:00 2001 From: Dean Sheather Date: Tue, 3 Jun 2025 18:05:40 +1000 Subject: [PATCH 1/2] fix: avoid build errors in CI --- scripts/Publish.ps1 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/Publish.ps1 b/scripts/Publish.ps1 index ee86980..6c0c101 100644 --- a/scripts/Publish.ps1 +++ b/scripts/Publish.ps1 @@ -113,7 +113,7 @@ if (Test-Path $buildPath) { New-Item -ItemType Directory -Path $buildPath -Force # Build in release mode -& dotnet.exe restore +& dotnet.exe restore /p:BuildWithNetFrameworkHostedCompiler=true if ($LASTEXITCODE -ne 0) { throw "Failed to dotnet restore" } $servicePublishDir = Join-Path $buildPath "service" & dotnet.exe publish .\Vpn.Service\Vpn.Service.csproj -c Release -a $arch -o $servicePublishDir /p:Version=$version From 9e6ed3f07e7578567066239e22c28331546d8c0a Mon Sep 17 00:00:00 2001 From: Dean Sheather Date: Tue, 3 Jun 2025 18:06:36 +1000 Subject: [PATCH 2/2] Update ci.yaml --- .github/workflows/ci.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 459579c..ac57947 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -21,7 +21,7 @@ jobs: cache: true cache-dependency-path: '**/packages.lock.json' - name: dotnet restore - run: dotnet restore --locked-mode + run: dotnet restore --locked-mode /p:BuildWithNetFrameworkHostedCompiler=true - name: dotnet format run: dotnet format --verify-no-changes --no-restore @@ -75,7 +75,7 @@ jobs: cache: true cache-dependency-path: '**/packages.lock.json' - name: dotnet restore - run: dotnet restore --locked-mode + run: dotnet restore --locked-mode /p:BuildWithNetFrameworkHostedCompiler=true # This doesn't call `dotnet publish` on the entire solution, just the # projects we care about building. Doing a full publish includes test # libraries and stuff which is pointless.