-
-
Notifications
You must be signed in to change notification settings - Fork 430
40 lines (37 loc) · 1.25 KB
/
codechecker.yml
File metadata and controls
40 lines (37 loc) · 1.25 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
33
34
35
36
37
38
39
40
name: CodeChecker
on:
workflow_call:
inputs:
run:
type: boolean
required: true
permissions: {}
jobs:
codechecker:
name: CodeChecker
if: ${{ inputs.run }}
runs-on: ubuntu-24.04
timeout-minutes: 60
defaults:
run:
shell: bash
steps:
- uses: actions/checkout@v6
- name: Install dependencies and codechecker
run: |
sudo apt-get -y update
sudo apt-get -y install libsdl2-dev libsdl2-mixer-dev libsdl2-image-dev clang-tools-18
python -m venv ~/.python-venv
~/.python-venv/bin/pip install codechecker
- name: Prepare compile_commands.json
run: |
cmake -B build -DCMAKE_BUILD_TYPE=Debug -DCMAKE_COMPILE_WARNING_AS_ERROR=ON -DENABLE_IMAGE=ON -DENABLE_TOOLS=ON -DCMAKE_EXPORT_COMPILE_COMMANDS=ON
- name: Analyze
run: |
export PATH=$HOME/.python-venv/bin:$PATH
CodeChecker analyze --analyzers clangsa --ctu-all --ctu-ast-mode load-from-pch --output codechecker-output \
--review-status-config .codechecker-review-status-config build/compile_commands.json
- name: Display results
run: |
export PATH=$HOME/.python-venv/bin:$PATH
CodeChecker parse --print-steps codechecker-output