Skip to content

Commit de8d527

Browse files
committed
sync
1 parent da3847d commit de8d527

File tree

1 file changed

+16
-1
lines changed

1 file changed

+16
-1
lines changed

.github/workflows/codeql.yml

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,9 @@ on:
66
- main
77
- release/*
88
pull_request:
9+
branches:
10+
- main
11+
- release/*
912
schedule:
1013
- cron: "07 04 * * 4" # weekly at 04:07 UTC on Thursday
1114

@@ -14,36 +17,48 @@ permissions:
1417

1518
jobs:
1619
analyze:
20+
name: Analyze (${{ matrix.language }})
1721
permissions:
1822
contents: read
1923
actions: read # for github/codeql-action/init to get workflow details
2024
security-events: write # for github/codeql-action/analyze to upload SARIF results
25+
strategy:
26+
fail-fast: false
27+
matrix:
28+
include:
29+
- language: actions
30+
- language: java
2131
runs-on: ubuntu-latest
2232
steps:
2333
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
2434

2535
- name: Set up Java 17
36+
if: matrix.language == 'java'
2637
uses: actions/setup-java@c5195efecf7bdfc987ee8bae7a71cb8b11521c00 # v4.7.1
2738
with:
2839
distribution: temurin
2940
java-version: 17
3041

3142
- name: Set up gradle
43+
if: matrix.language == 'java'
3244
uses: gradle/actions/setup-gradle@8379f6a1328ee0e06e2bb424dadb7b159856a326 # v4.4.0
3345

3446
- name: Initialize CodeQL
3547
uses: github/codeql-action/init@fca7ace96b7d713c7035871441bd52efbe39e27e # v3.28.19
3648
with:
37-
languages: java, actions
49+
languages: ${{ matrix.language }}
3850
# using "latest" helps to keep up with the latest Kotlin support
3951
# see https://github.com/github/codeql-action/issues/1555#issuecomment-1452228433
4052
tools: latest
4153

4254
- name: Assemble
55+
if: matrix.language == 'java'
4356
# --no-build-cache is required for codeql to analyze all modules
4457
# --no-daemon is required for codeql to observe the compilation
4558
# (see https://docs.github.com/en/code-security/codeql-cli/getting-started-with-the-codeql-cli/preparing-your-code-for-codeql-analysis#specifying-build-commands)
4659
run: ./gradlew assemble --no-build-cache --no-daemon
4760

4861
- name: Perform CodeQL analysis
4962
uses: github/codeql-action/analyze@fca7ace96b7d713c7035871441bd52efbe39e27e # v3.28.19
63+
with:
64+
category: "/language:${{matrix.language}}"

0 commit comments

Comments
 (0)