-
Notifications
You must be signed in to change notification settings - Fork 130
108 lines (86 loc) · 2.33 KB
/
cppcheck.yml
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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
name: cppcheck
on:
push:
paths-ignore:
- 'docker-compose/**'
- 'docs/**'
- 'README.md'
pull_request:
schedule:
- cron: '57 0 * * *'
jobs:
cppcheck-ubuntu:
timeout-minutes: 120
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
submodules: recursive
- name: Checkout cppcheck
uses: actions/checkout@v4
with:
repository: danmar/cppcheck
path: cppcheck-main
- name: Build cppcheck
run: |
cd cppcheck-main
make -j$(nproc) cppcheck
- name: cmake p2pool
run: |
mkdir build
cd build
cmake .. -DCMAKE_EXPORT_COMPILE_COMMANDS=ON -DSTATIC_LIBS=ON
python ../cppcheck/remove_external.py compile_commands.json
- name: Run cppcheck
run: |
cd cppcheck
./run.sh
- name: Archive full error list
uses: actions/upload-artifact@v4
with:
name: errors_full-linux
path: cppcheck/errors_full.txt
- name: Archive checkers report
uses: actions/upload-artifact@v4
with:
name: checkers_report-linux
path: cppcheck/checkers_report.txt
cppcheck-windows:
timeout-minutes: 60
runs-on: windows-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
submodules: recursive
- name: Checkout cppcheck
uses: actions/checkout@v4
with:
repository: danmar/cppcheck
path: cppcheck-main
- name: Build cppcheck
run: |
cd cppcheck-main
& "C:\\Program Files\\Microsoft Visual Studio\\2022\\Enterprise\\Msbuild\\Current\\Bin\\amd64\\msbuild.exe" -v:m /m /p:Configuration=Release /p:Platform=x64
- name: Setup cmake
uses: lukka/get-cmake@latest
- name: cmake p2pool
run: |
mkdir build
cd build
cmake .. -G "Visual Studio 17 2022" -DSTATIC_LIBS=ON
- name: Run cppcheck
run: |
cd cppcheck
./run.cmd
- name: Archive full error list
uses: actions/upload-artifact@v4
with:
name: errors_full-windows
path: cppcheck/errors_full.txt
- name: Archive checkers report
uses: actions/upload-artifact@v4
with:
name: checkers_report-windows
path: cppcheck/checkers_report.txt