From bbfd21d8bcd7ff4cfd7414cb05ae54803da1f41f Mon Sep 17 00:00:00 2001 From: Tyrrrz <1935960+Tyrrrz@users.noreply.github.com> Date: Mon, 3 Feb 2025 23:48:46 +0200 Subject: [PATCH] Improve the `format` workflow job --- .github/workflows/main.yml | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 6c5346049..fb5c31c4b 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -33,11 +33,24 @@ jobs: with: dotnet-version: 9.0.x + # Build the project separately to discern between build and format errors + - name: Build + run: > + dotnet build + -p:CSharpier_Bypass=true + --configuration Release + - name: Verify formatting + id: verify run: > dotnet build -t:CSharpierFormat --configuration Release + --no-restore + + - name: Report issues + if: ${{ failure() && steps.verify.outcome == 'failure' }} + run: echo "::error title=Bad formatting::Formatting issues detected. Please build the solution locally to fix them." pack: strategy: