Skip to content

add cpp linter (clang-tidy) workflow #5

add cpp linter (clang-tidy) workflow

add cpp linter (clang-tidy) workflow #5

Workflow file for this run

name: cpp-linter
on:
pull_request:
paths: ['**.cpp', '**.h', '**.hpp', '**CMakeLists.txt', '**.cmake', '.github/workflows/cpp-linter.yml']
jobs:
cpp-linter:
runs-on: ubuntu-latest
permissions:
contents: read
pull-requests: write
steps:
- name: install Linux deps
if: runner.os == 'Linux'
run: |
sudo apt-get update
sudo apt-get install -y libsnappy-dev libzzip-dev zlib1g-dev libboost-all-dev
- uses: actions/checkout@v5
- name: run cmake
run: |
cmake -Bbuild -DCMAKE_BUILD_TYPE=Debug -DCMAKE_EXPORT_COMPILE_COMMANDS=ON .
- name: C/C++ Linter
uses: cpp-linter/[email protected]
id: linter
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
version: 21
database: build
style: '' # disable clang-format checks.
tidy-checks: '' # Use .clang-tidy config file.