File tree Expand file tree Collapse file tree 1 file changed +15
-3
lines changed Expand file tree Collapse file tree 1 file changed +15
-3
lines changed Original file line number Diff line number Diff line change @@ -15,10 +15,22 @@ jobs:
15
15
uses : actions/checkout@v3
16
16
17
17
- name : Install dependencies
18
- run : sudo apt-get update && sudo apt-get install -y cmake libgtest-dev
18
+ run : |
19
+ sudo apt-get update
20
+ sudo apt-get install -y cmake clang clang-tidy libgtest-dev ninja-build
19
21
20
- - name : Configure CMake
21
- run : cmake -S . -B build
22
+ - name : Configure CMake (with Clang-Tidy)
23
+ run : |
24
+ cmake -S . -B build \
25
+ -DENABLE_CLANG_TIDY=ON \
26
+ -DCMAKE_EXPORT_COMPILE_COMMANDS=ON \
27
+ -G Ninja
28
+
29
+ - name : Run Clang-Tidy
30
+ run : |
31
+ echo "Running Clang-Tidy..."
32
+ find SourceCodes Headers Tests -name '*.cpp' -o -name '*.h' | xargs clang-tidy -p build
33
+ continue-on-error : false # Fail pipeline if any warning occurs
22
34
23
35
- name : Build
24
36
run : cmake --build build
You can’t perform that action at this time.
0 commit comments