-
-
Notifications
You must be signed in to change notification settings - Fork 415
32 lines (29 loc) · 1.13 KB
/
Copy pathcppcheck.yml
File metadata and controls
32 lines (29 loc) · 1.13 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
name: CppCheck
on: [push, pull_request]
jobs:
cppcheck:
runs-on: ubuntu-latest
timeout-minutes: 30
steps:
- uses: actions/checkout@v7
- name: Install CppCheck
timeout-minutes: 15
run: |
if [[ -f /etc/apt/apt-mirrors.txt ]]; then
sudo sed -i '/azure\.archive\.ubuntu\.com/d' /etc/apt/apt-mirrors.txt
fi
sudo -H apt-get update -y
sudo -H apt-get install -y cppcheck
env:
DEBIAN_FRONTEND: noninteractive
- name: Run Cppcheck
run: cppcheck --std=c++11 -ithird_party/wavelib -ithird_party/spdlog -ithird_party/libsvm -ithird_party/SimpleBLE -ithird_party/fmt -ithird_party/SimpleDBus -ithird_party/SimpleBluez -ithird_party/kissfft -isrc/utils/os_serial_ioctl.cpp --error-exitcode=1 --xml --xml-version=2 --force src cpp_package third_party 2>cppcheck_res.xml
- name: Generate Report
if: ${{ failure() }}
run: cppcheck-htmlreport --title=BrainFlow --file=cppcheck_res.xml --report-dir=report
- name: Upload Report
if: ${{ failure() }}
uses: actions/upload-artifact@v4
with:
name: report
path: report