diff --git a/.github/workflows/clang-format-check.yml b/.github/workflows/clang-format-check.yml new file mode 100644 index 0000000..a89eb90 --- /dev/null +++ b/.github/workflows/clang-format-check.yml @@ -0,0 +1,18 @@ +name: clang-format Check +on: [push, pull_request] +jobs: + formatting-check: + name: Formatting Check + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + + - name: Install clang-format + run: | + apt-get update + apt-get install -y clang-format-19 + + - name: Run clang-format check + run: | + find Source -name '*.cpp' -o -name '*.hpp' -o -name '*.c' -o -name '*.h' | \ + xargs clang-format-19 --dry-run --Werror \ No newline at end of file