Skip to content

Commit 656e9a5

Browse files
committed
feat: codeql check added
1 parent d76d902 commit 656e9a5

File tree

3 files changed

+90
-1
lines changed

3 files changed

+90
-1
lines changed

.github/codeql/config.yml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
name: "CodeQL Config"
2+
3+
# Queries and the suites they belong to are documented at
4+
# https://codeql.github.com/codeql-query-help/cpp/
5+
6+
queries:
7+
- uses: security-and-quality
8+
# Choose the above from 3 query suites:
9+
# default
10+
# The default set of queries
11+
# security-extended
12+
# `default` suite plus lower severity and precision queries
13+
# security-and-quality
14+
# `security-extended`, plus maintainability and reliability queries
15+
16+
query-filters:
17+
-
18+
exclude:
19+
id: cpp/use-of-goto
20+
-
21+
exclude:
22+
problem.severity: recommendation

.github/workflows/module-build.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
# Set the 'name:' properties to values that work for you (pvxs)
77

8-
name: devlib2
8+
name: Module Build and Test
99

1010
# Trigger on pushes and PRs to any branch
1111
on:
Lines changed: 67 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
name: CodeQL Module
2+
3+
on:
4+
push:
5+
branches: [master, gha]
6+
paths:
7+
- ".github/workflows/module-codeql.yml"
8+
- "common/**"
9+
- "linux/**"
10+
- "exploreApp/**"
11+
- "pciApp/**"
12+
- "vmeApp/**"
13+
pull_request:
14+
branches: [master]
15+
paths:
16+
- ".github/workflows/module-codeql.yml"
17+
- "common/**"
18+
- "linux/**"
19+
- "exploreApp/**"
20+
- "pciApp/**"
21+
- "vmeApp/**"
22+
23+
permissions:
24+
contents: read
25+
security-events: write
26+
27+
env:
28+
SETUP_PATH: .ci-local:.ci
29+
BASE: "7.0"
30+
CMP: gcc
31+
BCFG: default
32+
33+
jobs:
34+
analyze:
35+
name: Analyze
36+
runs-on: ubuntu-latest
37+
38+
steps:
39+
- name: Checkout
40+
uses: actions/checkout@v4
41+
with:
42+
submodules: true
43+
fetch-depth: 0
44+
45+
- name: Deps
46+
run: |
47+
sudo apt-get update
48+
sudo apt-get -y install qemu-system-x86 gdb
49+
50+
- name: Prepare deps (ci-scripts)
51+
run: python3 .ci/cue.py prepare
52+
53+
- name: Initialize CodeQL (manual build)
54+
uses: github/codeql-action/init@v3
55+
with:
56+
languages: cpp
57+
build-mode: manual
58+
config-file: ./.github/codeql/config.yml
59+
60+
- name: Build (ci-scripts)
61+
run: |
62+
python3 .ci/cue.py build
63+
64+
- name: Analyze
65+
uses: github/codeql-action/analyze@v3
66+
with:
67+
category: "/language:cpp"

0 commit comments

Comments
 (0)