feat: clang-tidy code style action #20
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build YANET | |
on: | |
push: | |
branches: ["main"] | |
# paths: ["**.h", "**.c", "**/meson.build"] | |
pull_request: | |
branches: ["main"] | |
# paths: ["**.h", "**.c", "**/meson.build"] | |
jobs: | |
build: | |
runs-on: ubuntu-24.04 | |
steps: | |
- uses: awalsh128/cache-apt-pkgs-action@latest | |
with: | |
packages: meson clang python3-pyelftools libnuma-dev libpcap-dev git | |
version: 1.0 | |
- uses: actions/checkout@v4 | |
with: | |
submodules: true | |
- uses: hendrikmuhs/[email protected] | |
name: ccache | |
with: | |
key: ${{ runner.os }}-build-cache | |
- run: | | |
meson setup build -Dbuildtype=debug | |
meson compile -C build | |
- uses: cpp-linter/cpp-linter-action@main | |
id: linter | |
continue-on-error: true | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
database: build | |
style: file | |
# Use .clang-tidy config file. | |
tidy-checks: '' | |
version: 19 | |
thread-comments: false | |
step-summary: true | |
tidy-review: false | |
format-review: false | |
files-changed-only: false | |
- name: Check code style violation | |
if: steps.linter.outputs.clang-tidy-checks-failed > 0 | |
run: exit 1 |