Fix CI: use dotnet msbuild -restore to properly disable analyzers

The separate restore + build steps caused StyleCop analyzers to be
restored unconditionally, then EnableAnalyzers=false had no effect
since packages were already resolved. Using dotnet msbuild -restore
(matching upstream build.sh) passes the property during both restore
and build phases.
This commit is contained in:
nitrobass24 2026-02-27 18:29:26 -06:00
parent 1785cc0827
commit 3f9aca3fe0

View file

@ -46,14 +46,10 @@ jobs:
with:
dotnet-version: ${{ env.DOTNET_VERSION }}
- name: Restore
run: dotnet restore src/Prowlarr.sln
- name: Build
run: >-
dotnet build src/Prowlarr.sln
--no-restore
-c Release
dotnet msbuild -restore src/Prowlarr.sln
-p:Configuration=Release
-p:Platform=${{ matrix.platform }}
-p:EnableAnalyzers=false
@ -85,14 +81,10 @@ jobs:
with:
dotnet-version: ${{ env.DOTNET_VERSION }}
- name: Restore
run: dotnet restore src/Prowlarr.sln
- name: Build
run: >-
dotnet build src/Prowlarr.sln
--no-restore
-c Release
dotnet msbuild -restore src/Prowlarr.sln
-p:Configuration=Release
-p:Platform=${{ matrix.platform }}
-p:EnableAnalyzers=false