Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mumble-voip/mumble.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobert Adam <dev@robert-adam.de>2021-04-18 21:33:19 +0300
committerRobert Adam <dev@robert-adam.de>2021-04-18 21:33:19 +0300
commit8ed36e8246d26a15cfd9ab5882f8271b0b3a02b6 (patch)
treeda143a8310103b42eb2baa117dd48b0c00229232
parent0f45328cd1477080cc261a6795a69df07f6f645d (diff)
CI: Check code-formatting
This new check will fail if there is a c++ source code file that is not formatted according to our project's formatting standards (specified via .clang-format file).
-rw-r--r--.github/workflows/pr-checks.yml17
1 files changed, 17 insertions, 0 deletions
diff --git a/.github/workflows/pr-checks.yml b/.github/workflows/pr-checks.yml
index 65c715f88..cc6151542 100644
--- a/.github/workflows/pr-checks.yml
+++ b/.github/workflows/pr-checks.yml
@@ -29,3 +29,20 @@ jobs:
uses: erclu/check-crlf@v1
with:
exclude: '3rdparty/'
+
+ - uses: ./.github/actions/install-dependencies
+ with:
+ type: shared
+ os: ubuntu-20.04
+ arch: 64bit
+
+ - name: Generate compile-command DB
+ run: mkdir build; cd build; cmake -DCMAKE_EXPORT_COMPILE_COMMANDS=ON ..; cd ..; ln -s build/compile_commands.json .
+ shell: bash
+
+ - name: Check code formatting
+ uses: jidicula/clang-format-action@v3.3.0
+ with:
+ clang-format-version: '10'
+ check-path: '.'
+ exclude-regex: '(3rdparty/*|build/*)'