Skip to content

Bug Fixes and Performance Improvements #26

Bug Fixes and Performance Improvements

Bug Fixes and Performance Improvements #26

Workflow file for this run

name: C++ Code Analysis
on:
push:
branches:
- master
pull_request:
branches:
- master
jobs:
build-and-analyze:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Install C++ tools
run: sudo apt-get update && sudo apt-get install -y clang clang-tidy cppcheck cmake
- name: List directory contents
run: ls -R
- name: Check for CMakeLists.txt
run: |
if [ ! -f ./CMakeLists.txt ]; then
echo "CMakeLists.txt not found in the root directory."
exit 1
fi
- name: Create build directory
run: mkdir build
- name: Run CMake
run: cmake -S . -B build
- name: Build project
run: cmake --build build
- name: Run cppcheck
run: cppcheck --enable=all --inconclusive --xml --xml-version=2 . 2> cppcheck-result.xml
- name: Run clang-tidy
run: find . -name '*.cpp' | xargs clang-tidy -p build
- name: Upload cppcheck results
uses: actions/upload-artifact@v3
with:
name: cppcheck-result
path: cppcheck-result.xml