File tree Expand file tree Collapse file tree 2 files changed +36
-116
lines changed
Expand file tree Collapse file tree 2 files changed +36
-116
lines changed Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1717 DOTNET_CLI_TELEMETRY_OPTOUT : true
1818
1919jobs :
20+ format :
21+ runs-on : ubuntu-latest
22+ timeout-minutes : 10
23+
24+ permissions :
25+ contents : read
26+
27+ steps :
28+ - name : Checkout
29+ uses : actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
30+
31+ - name : Install .NET
32+ uses : actions/setup-dotnet@3951f0dfe7a07e2313ec93c75700083e2005cbab # v4.3.0
33+ with :
34+ dotnet-version : 9.0.x
35+
36+ # Build the project separately to discern between build and format errors
37+ - name : Build
38+ run : >
39+ dotnet build
40+ -p:CSharpier_Bypass=true
41+ --configuration Release
42+
43+ - name : Verify formatting
44+ id : verify
45+ run : >
46+ dotnet build
47+ -t:CSharpierFormat
48+ --configuration Release
49+ --no-restore
50+
51+ - name : Report issues
52+ if : ${{ failure() && steps.verify.outcome == 'failure' }}
53+ run : echo "::error title=Bad formatting::Formatting issues detected. Please build the solution locally to fix them."
54+
2055 test :
2156 runs-on : ubuntu-latest
2257 timeout-minutes : 10
@@ -111,6 +146,7 @@ jobs:
111146 if : ${{ github.ref_type == 'tag' }}
112147
113148 needs :
149+ - format
114150 - test
115151 - pack
116152
You can’t perform that action at this time.
0 commit comments