Skip to content

Commit 9b6770b

Browse files
authored
Update codeql-analysis.yml
1 parent e81843d commit 9b6770b

File tree

1 file changed

+14
-42
lines changed

1 file changed

+14
-42
lines changed
Lines changed: 14 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,10 @@
1-
# For most projects, this workflow file will not need changing; you simply need
2-
# to commit it to your repository.
3-
#
4-
# You may wish to alter this file to override the set of languages analyzed,
5-
# or to provide custom queries or build logic.
6-
#
7-
# ******** NOTE ********
8-
# We have attempted to detect the languages in your repository. Please check
9-
# the `language` matrix defined below to confirm you have the correct set of
10-
# supported CodeQL languages.
11-
#
1+
122
name: "CodeQL"
133

144
on:
155
push:
166
branches: [ master ]
177
pull_request:
18-
# The branches below must be a subset of the branches above
198
branches: [ master ]
209
schedule:
2110
- cron: '32 3 * * 3'
@@ -24,44 +13,27 @@ jobs:
2413
analyze:
2514
name: Analyze
2615
runs-on: ubuntu-latest
27-
16+
permissions:
17+
actions: read
18+
contents: read
19+
security-events: write
2820
strategy:
2921
fail-fast: false
3022
matrix:
3123
language: [ 'java' ]
32-
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python' ]
33-
# Learn more:
34-
# https://docs.github.com/en/free-pro-team@latest/github/finding-security-vulnerabilities-and-errors-in-your-code/configuring-code-scanning#changing-the-languages-that-are-analyzed
35-
3624
steps:
3725
- name: Checkout repository
38-
uses: actions/checkout@v2
39-
40-
# Initializes the CodeQL tools for scanning.
26+
uses: actions/checkout@v3
4127
- name: Initialize CodeQL
42-
uses: github/codeql-action/init@v1
28+
uses: github/codeql-action/init@v2
4329
with:
4430
languages: ${{ matrix.language }}
45-
# If you wish to specify custom queries, you can do so here or in a config file.
46-
# By default, queries listed here will override any specified in a config file.
47-
# Prefix the list here with "+" to use these queries and those in the config file.
48-
# queries: ./path/to/local/query, your-org/your-repo/queries@main
49-
50-
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
51-
# If this step fails, then you should remove it and run the build manually (see below)
31+
- name: Set up JDK 11
32+
uses: actions/setup-java@v2
33+
with:
34+
java-version: 11
35+
distribution: 'zulu'
5236
- name: Autobuild
53-
uses: github/codeql-action/autobuild@v1
54-
55-
# ℹ️ Command-line programs to run using the OS shell.
56-
# 📚 https://git.io/JvXDl
57-
58-
# ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
59-
# and modify them (or add more) to build your code if your project
60-
# uses a compiled language
61-
62-
#- run: |
63-
# make bootstrap
64-
# make release
65-
37+
uses: github/codeql-action/autobuild@v2
6638
- name: Perform CodeQL Analysis
67-
uses: github/codeql-action/analyze@v1
39+
uses: github/codeql-action/analyze@v2

0 commit comments

Comments
 (0)