Worksheet 5 #248
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: code-quality | |
on: | |
pull_request: | |
branches: | |
- master | |
- ws* | |
jobs: | |
check-format: | |
runs-on: ubuntu-24.04 | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
submodules: true | |
- run: find src -iname "*.h" -o -iname "*.cpp" | xargs clang-format-18 --dry-run --Werror | |
- run: find test -iname "*.h" -o -iname "*.cpp" | xargs clang-format-18 --dry-run --Werror | |
check-clang-tidy: | |
runs-on: ubuntu-24.04 | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
submodules: true | |
- run: sudo apt-get install libxerces-c-dev | |
- run: cmake -DCMAKE_TOOLCHAIN_FILE=./toolchains/clang-test.cmake -DCMAKE_EXPORT_COMPILE_COMMANDS=ON -G 'Unix Makefiles' -S $(pwd) -B $(pwd)/build | |
- run: cd ./build && make VERBOSE=1 -j5 | |
- run: clang-tidy-18 src/**/*.{cpp,h} -p ./build/compile_commands.json |