mirror of
https://github.com/SChernykh/p2pool.git
synced 2024-09-11 16:18:47 -06:00
40 lines
960 B
YAML
40 lines
960 B
YAML
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 17
|
|
sudo apt-get install -y clang-tidy-17
|
|
clang-tidy-17 --verify-config
|
|
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v3
|
|
with:
|
|
submodules: true
|
|
|
|
- name: cmake p2pool
|
|
run: |
|
|
mkdir build
|
|
cd build
|
|
cmake .. -DCMAKE_EXPORT_COMPILE_COMMANDS=ON -DCMAKE_C_COMPILER=clang-17 -DCMAKE_CXX_COMPILER=clang++-17 -DDEV_CLANG_TIDY=ON -DSTATIC_LIBS=ON
|
|
|
|
- name: Run clang-tidy
|
|
run: |
|
|
cd src
|
|
clang-tidy-17 *.cpp -p ../build -checks=-clang-diagnostic-undefined-internal,-clang-analyzer-optin.performance.Padding -warnings-as-errors=* -header-filter=^[^\.]
|