@@ -4,13 +4,15 @@ name: "CodeQL"
44
55on :
66 pull_request :
7- # The branches below must be a subset of the branches above, now enable it in all PR
8- # branches: [ master ]
7+ # The branches below must be a subset of the branches above, now enable it in all PR
8+ # branches: [ master ]
99 schedule :
1010 - cron : ' 45 7 * * 1'
1111
1212jobs :
1313 analyze :
14+ env :
15+ USE_STAGE : ' true' # Whether to include the stage repository.
1416 name : Analyze
1517 runs-on : ubuntu-latest
1618 permissions :
@@ -24,43 +26,55 @@ jobs:
2426 language : [ 'go', 'java' ]
2527
2628 steps :
27- - name : Checkout repository
28- uses : actions/checkout@v3
29+ - name : Checkout repository
30+ uses : actions/checkout@v4
2931
30- # Initializes the CodeQL tools for scanning.
31- - name : Initialize CodeQL
32- uses : github/codeql-action/init@v2
33- with :
34- languages : ${{ matrix.language }}
35- # If you wish to specify custom queries, you can do so here or in a config file.
36- # By default, queries listed here will override any specified in a config file.
37- # Prefix the list here with "+" to use these queries and those in the config file.
38- # queries: ./path/to/local/query, your-org/your-repo/queries@main
32+ - name : Setup Java JDK
33+ uses : actions/setup-java@v3
34+ with :
35+ distribution : ' zulu'
36+ java-version : ' 11'
3937
40- # Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
41- # If this step fails, then you should remove it and run the build manually (see below)
42- - name : Autobuild
43- uses : github/codeql-action/autobuild@v2
38+ - name : use staged maven repo settings
39+ if : ${{ env.USE_STAGE == 'true' }}
40+ run : |
41+ cp $HOME/.m2/settings.xml /tmp/settings.xml
42+ mv -vf .github/configs/settings.xml $HOME/.m2/settings.xml
4443
45- # ℹ️ Command-line programs to run using the OS shell.
46- # 📚 https://git.io/JvXDl
44+ # Initializes the CodeQL tools for scanning.
45+ - name : Initialize CodeQL
46+ uses : github/codeql-action/init@v2
47+ with :
48+ languages : ${{ matrix.language }}
49+ # If you wish to specify custom queries, you can do so here or in a config file.
50+ # By default, queries listed here will override any specified in a config file.
51+ # Prefix the list here with "+" to use these queries and those in the config file.
52+ # queries: ./path/to/local/query, your-org/your-repo/queries@main
4753
48- # ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
49- # and modify them (or add more) to build your code if your project
50- # uses a compiled language
54+ # Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
55+ # If this step fails, then you should remove it and run the build manually (see below)
56+ - name : Autobuild
57+ uses : github/codeql-action/autobuild@v2
5158
52- # - run: |
53- # make bootstrap
54- # make release
59+ # ℹ️ Command-line programs to run using the OS shell.
60+ # 📚 https://git.io/JvXDl
5561
56- - name : Perform CodeQL Analysis
57- uses : github/codeql-action/analyze@v2
62+ # ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
63+ # and modify them (or add more) to build your code if your project
64+ # uses a compiled language
65+
66+ # - run: |
67+ # make bootstrap
68+ # make release
69+
70+ - name : Perform CodeQL Analysis
71+ uses : github/codeql-action/analyze@v2
5872
5973 dependency-review :
6074 runs-on : ubuntu-latest
6175 steps :
6276 - name : ' Checkout Repository'
63- uses : actions/checkout@v3
77+ uses : actions/checkout@v4
6478 - name : ' Dependency Review'
6579 uses : actions/dependency-review-action@v3
6680
0 commit comments