ci: code format check (#1487)

This commit is contained in:
Nathan Baulch
2025-07-02 12:54:22 +10:00
committed by GitHub
parent fc188e2344
commit 4f266a2342
3 changed files with 23 additions and 1 deletions

View File

@@ -12,7 +12,6 @@ indent_style = space
indent_size = 4
dotnet_style_operator_placement_when_wrapping = beginning_of_line
tab_width = 4
end_of_line = crlf
dotnet_style_coalesce_expression = true:suggestion
dotnet_style_null_propagation = true:suggestion
dotnet_style_prefer_is_null_check_over_reference_equality_method = true:suggestion

22
.github/workflows/format-check.yml vendored Normal file
View File

@@ -0,0 +1,22 @@
name: Format Check
on:
push:
branches: [ develop ]
workflow_dispatch:
workflow_call:
jobs:
format-check:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 9.0.x
- name: Run formatting check
run: dotnet format --verify-no-changes

View File

@@ -18,6 +18,7 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "workflows", "workflows", "{
.github\workflows\package.yml = .github\workflows\package.yml
.github\workflows\release.yml = .github\workflows\release.yml
.github\workflows\localization-check.yml = .github\workflows\localization-check.yml
.github\workflows\format-check.yml = .github\workflows\format-check.yml
EndProjectSection
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "src", "src", "{49A7C2D6-558C-4FAA-8F5D-EEE81497AED7}"