Skip to content

Commit 4d4b08d

Browse files
committed
Fix #372, CodeQL Query Suites
1 parent 6df5bdc commit 4d4b08d

File tree

3 files changed

+23
-22
lines changed

3 files changed

+23
-22
lines changed

.github/codeql/codeql-coding-standard.yml

+2-14
Original file line numberDiff line numberDiff line change
@@ -3,17 +3,5 @@ name: "CodeQL Coding Standard Configuration File"
33
disable-default-queries: true
44

55
queries:
6-
- name: JPL Rules
7-
uses: github/codeql/cpp/ql/src/JPL_C@main
8-
- name: MISRA Rule 9-5-1
9-
uses: github/codeql/cpp/ql/src/jsf/4.20 Unions and Bit Fields/AV Rule 153.ql@main
10-
- name: MISRA Rule 5-18-1
11-
uses: github/codeql/cpp/ql/src/jsf/4.21 Operators/AV Rule 168.ql@main
12-
- name: MISRA 6-2-2
13-
uses: github/codeql/cpp/ql/src/jsf/4.25 Expressions/AV Rule 202.ql@main
14-
- name: MISRA Rule 5-14-1
15-
uses: github/codeql/cpp/ql/src/jsf/4.21 Operators/AV Rule 165.ql@main
16-
- name: MISRA Rule 5-3-2
17-
uses: github/codeql/cpp/ql/src/jsf/4.21 Operators/AV Rule 165.ql@main
18-
- name: MISRA Rule 7-5-2
19-
uses: github/codeql/cpp/ql/src/jsf/4.22 Pointers and References/AV Rule 173.ql@main
6+
- name: JPL and MISRA
7+
uses: ./.github/codeql/jpl-misra.qls

.github/codeql/jpl-misra.qls

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# Start with all the queries in the codeql/cpp-queries pack.
2+
- queries: .
3+
from: codeql/cpp-queries
4+
# Restrict to only the queries with the following ID patterns.
5+
- include:
6+
id:
7+
# Regular expression matching all query IDs that start with `cpp/jpl-c/`
8+
# This covers all queries in the `JPL_C` directory,
9+
# but matching on query ID is more stable.
10+
- /cpp/jpl-c/*/
11+
# Specific JSF queries, identified by query ID.
12+
# MISRA Rule 9-5-1
13+
- cpp/jsf/av-rule-153
14+
# MISRA Rule 5-18-1
15+
- cpp/jsf/av-rule-168
16+
# MISRA 6-2-2
17+
- cpp/jsf/av-rule-202
18+
# MISRA Rule 5-14-1
19+
- cpp/jsf/av-rule-165
20+
# MISRA Rule 5-3-2
21+
- cpp/jsf/av-rule-173

.github/workflows/codeql-build.yml

-8
Original file line numberDiff line numberDiff line change
@@ -96,14 +96,6 @@ jobs:
9696
git log -1 --pretty=oneline
9797
git submodule
9898
99-
- name: Checkout codeql code
100-
if: ${{ !steps.skip-workflow.outputs.skip }}
101-
uses: actions/checkout@v2
102-
with:
103-
repository: github/codeql
104-
submodules: true
105-
path: codeql
106-
10799
- name: Initialize CodeQL
108100
if: ${{ !steps.skip-workflow.outputs.skip }}
109101
uses: github/codeql-action/init@v1

0 commit comments

Comments
 (0)