Skip to content

Commit 6f030cb

Browse files
authored
ci: add codeql (#621)
1 parent 4330268 commit 6f030cb

File tree

1 file changed

+69
-0
lines changed

1 file changed

+69
-0
lines changed

.github/workflows/codeql.yml

Lines changed: 69 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,69 @@
1+
#
2+
# Licensed to the Apache Software Foundation (ASF) under one or more
3+
# contributor license agreements. See the NOTICE file distributed with
4+
# this work for additional information regarding copyright ownership.
5+
# The ASF licenses this file to You under the Apache License, Version 2.0
6+
# (the "License"); you may not use this file except in compliance with
7+
# the License. You may obtain a copy of the License at
8+
#
9+
# http://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
# Unless required by applicable law or agreed to in writing, software
12+
# distributed under the License is distributed on an "AS IS" BASIS,
13+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
# See the License for the specific language governing permissions and
15+
# limitations under the License.
16+
#
17+
18+
# For most projects, this workflow file will not need changing; you simply need
19+
# to commit it to your repository.
20+
#
21+
# You may wish to alter this file to override the set of languages analyzed,
22+
# or to provide custom queries or build logic.
23+
#
24+
# ******** NOTE ********
25+
# We have attempted to detect the languages in your repository. Please check
26+
# the `language` matrix defined below to confirm you have the correct set of
27+
# supported CodeQL languages.
28+
#
29+
30+
name: CodeQL
31+
32+
on:
33+
pull_request:
34+
# The branches below must be a subset of the branches above
35+
branches: "*"
36+
37+
permissions:
38+
contents: read
39+
40+
jobs:
41+
analyse:
42+
permissions:
43+
actions: read # for github/codeql-action/init to get workflow details
44+
contents: read # for actions/checkout to fetch code
45+
security-events: write # for github/codeql-action/autobuild to send a status report
46+
name: Analyse
47+
runs-on: ubuntu-latest
48+
49+
steps:
50+
- name: Checkout repository
51+
uses: actions/checkout@v3
52+
with:
53+
# We must fetch at least the immediate parents so that if this is
54+
# a pull request then we can checkout the head.
55+
fetch-depth: 2
56+
57+
# Initializes the CodeQL tools for scanning.
58+
- name: Initialize CodeQL
59+
uses: github/codeql-action/init@v2
60+
61+
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
62+
# If this step fails, then you should remove it and run the build manually (see below)
63+
- name: Autobuild
64+
uses: github/codeql-action/autobuild@v2
65+
66+
# Analysis
67+
- name: Perform CodeQL Analysis
68+
uses: github/codeql-action/analyze@v2
69+

0 commit comments

Comments
 (0)