-
-
Notifications
You must be signed in to change notification settings - Fork 18
71 lines (64 loc) · 1.98 KB
/
codeql.yml
File metadata and controls
71 lines (64 loc) · 1.98 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
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
name: "CodeQL Advanced"
on:
push:
branches: [ "master" ]
paths:
- "src/**"
- ".github/workflows/**"
pull_request:
types: [ opened, reopened, synchronize, ready_for_review ]
branches: [ "master" ]
paths:
- "src/**"
- ".github/workflows/**"
schedule:
- cron: '15 22 * * 2'
env:
DOTNET_VERSION: 10.0.x
jobs:
analyze:
name: Analyze (${{ matrix.language }})
if: ${{ github.event_name != 'pull_request' || !github.event.pull_request.draft }}
runs-on: ${{ matrix.os }}
permissions:
security-events: write
packages: read
actions: read
contents: read
strategy:
fail-fast: false
matrix:
include:
- language: actions
build-mode: none
os: ubuntu-latest
- language: csharp
build-mode: autobuild
os: windows-latest
steps:
- name: Checkout repository
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- name: Use .NET ${{ env.DOTNET_VERSION }}
if: matrix.language == 'csharp'
uses: actions/setup-dotnet@c2fa09f4bde5ebb9d1777cf28262a3eb3db3ced7 # v5.2.0
with:
dotnet-version: ${{ env.DOTNET_VERSION }}
- name: Initialize CodeQL
uses: github/codeql-action/init@38697555549f1db7851b81482ff19f1fa5c4fedc # v4.34.1
with:
languages: ${{ matrix.language }}
build-mode: ${{ matrix.build-mode }}
- name: Run manual build steps
if: matrix.build-mode == 'manual'
shell: bash
run: |
echo 'If you are using a "manual" build mode for one or more of the' \
'languages you are analyzing, replace this with the commands to build' \
'your code, for example:'
echo ' make bootstrap'
echo ' make release'
exit 1
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@38697555549f1db7851b81482ff19f1fa5c4fedc # v4.34.1
with:
category: "/language:${{matrix.language}}"