-
Notifications
You must be signed in to change notification settings - Fork 130
39 lines (32 loc) · 1005 Bytes
/
clang-tidy.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
name: clang-tidy
on:
push:
paths-ignore:
- 'docker-compose/**'
- 'docs/**'
- 'README.md'
pull_request:
jobs:
clang-tidy:
runs-on: ubuntu-22.04
steps:
- name: Install clang
run: |
wget https://apt.llvm.org/llvm.sh
chmod +x llvm.sh
sudo ./llvm.sh 19
sudo apt-get install -y clang-tidy-19
clang-tidy-19 --verify-config
- name: Checkout repository
uses: actions/checkout@v4
with:
submodules: recursive
- name: cmake p2pool
run: |
mkdir build
cd build
cmake .. -DCMAKE_EXPORT_COMPILE_COMMANDS=ON -DCMAKE_C_COMPILER=clang-19 -DCMAKE_CXX_COMPILER=clang++-19 -DDEV_CLANG_TIDY=ON -DSTATIC_LIBS=ON
- name: Run clang-tidy
run: |
cd src
clang-tidy-19 *.cpp -p ../build -checks=-clang-diagnostic-undefined-internal,-clang-analyzer-optin.performance.Padding,-clang-diagnostic-nan-infinity-disabled -warnings-as-errors=* -header-filter=^[^\.]