|
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 | | -# |
12 | | -name: "CodeQL" |
| 1 | +name: "CodeQL analysis" |
13 | 2 |
|
14 | 3 | on: |
15 | 4 | push: |
16 | | - branches: [ main ] |
| 5 | + branches: [main] |
17 | 6 | pull_request: |
18 | | - # The branches below must be a subset of the branches above |
19 | | - branches: [ main ] |
| 7 | + branches: [main] |
20 | 8 | schedule: |
21 | | - - cron: '39 7 * * 2' |
| 9 | + # ┌───────────── minute (0 - 59) |
| 10 | + # │ ┌───────────── hour (0 - 23) |
| 11 | + # │ │ ┌───────────── day of the month (1 - 31) |
| 12 | + # │ │ │ ┌───────────── month (1 - 12 or JAN-DEC) |
| 13 | + # │ │ │ │ ┌───────────── day of the week (0 - 6 or SUN-SAT) |
| 14 | + # │ │ │ │ │ |
| 15 | + # │ │ │ │ │ |
| 16 | + # │ │ │ │ │ |
| 17 | + # * * * * * |
| 18 | + - cron: '30 1 * * 0' |
22 | 19 |
|
23 | 20 | jobs: |
24 | 21 | analyze: |
25 | 22 | name: Analyze |
| 23 | + # CodeQL runs on ubuntu-latest, windows-latest, and macos-latest |
26 | 24 | runs-on: ubuntu-latest |
| 25 | + |
27 | 26 | permissions: |
28 | | - actions: read |
29 | | - contents: read |
| 27 | + # required for all workflows |
30 | 28 | security-events: write |
31 | 29 |
|
32 | | - strategy: |
33 | | - fail-fast: false |
34 | | - matrix: |
35 | | - language: [ 'javascript' ] |
36 | | - # CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python', 'ruby' ] |
37 | | - # Learn more about CodeQL language support at https://git.io/codeql-language-support |
| 30 | + # only required for workflows in private repositories |
| 31 | + actions: read |
| 32 | + contents: read |
38 | 33 |
|
39 | 34 | steps: |
40 | | - - name: Checkout repository |
41 | | - uses: actions/checkout@v3 |
42 | | - |
43 | | - # Initializes the CodeQL tools for scanning. |
44 | | - - name: Initialize CodeQL |
45 | | - uses: github/codeql-action/init@v2 |
46 | | - with: |
47 | | - # Run extended queries including queries using machine learning |
48 | | - queries: security-extended |
49 | | - languages: ${{ matrix.language }} |
50 | | - # If you wish to specify custom queries, you can do so here or in a config file. |
51 | | - # By default, queries listed here will override any specified in a config file. |
52 | | - # Prefix the list here with "+" to use these queries and those in the config file. |
53 | | - # queries: ./path/to/local/query, your-org/your-repo/queries@main |
54 | | - |
55 | | - # Autobuild attempts to build any compiled languages (C/C++, C#, or Java). |
56 | | - # If this step fails, then you should remove it and run the build manually (see below) |
57 | | - - name: Autobuild |
58 | | - uses: github/codeql-action/autobuild@v2 |
59 | | - |
60 | | - # ℹ️ Command-line programs to run using the OS shell. |
61 | | - # 📚 https://git.io/JvXDl |
62 | | - |
63 | | - # ✏️ If the Autobuild fails above, remove it and uncomment the following three lines |
64 | | - # and modify them (or add more) to build your code if your project |
65 | | - # uses a compiled language |
66 | | - |
67 | | - #- run: | |
68 | | - # make bootstrap |
69 | | - # make release |
70 | | - |
71 | | - - name: Perform CodeQL Analysis |
72 | | - uses: github/codeql-action/analyze@v2 |
| 35 | + - name: Checkout |
| 36 | + uses: actions/checkout@v3 |
| 37 | + |
| 38 | + # Initializes the CodeQL tools for scanning. |
| 39 | + - name: Initialize CodeQL |
| 40 | + uses: github/codeql-action/init@v2 |
| 41 | + with: |
| 42 | + # Run extended queries including queries using machine learning |
| 43 | + queries: security-extended |
| 44 | + languages: ${{ matrix.language }} |
| 45 | + |
| 46 | + # Autobuild attempts to build any compiled languages (C/C++, C#, Go, or Java). |
| 47 | + # If this step fails, then you should remove it and run the build manually (see below). |
| 48 | + - name: Autobuild |
| 49 | + uses: github/codeql-action/autobuild@v2 |
| 50 | + |
| 51 | + # ℹ️ Command-line programs to run using the OS shell. |
| 52 | + # 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun |
| 53 | + |
| 54 | + # ✏️ If the Autobuild fails above, remove it and uncomment the following |
| 55 | + # three lines and modify them (or add more) to build your code if your |
| 56 | + # project uses a compiled language |
| 57 | + |
| 58 | + #- run: | |
| 59 | + # make bootstrap |
| 60 | + # make release |
| 61 | + |
| 62 | + - name: Perform CodeQL Analysis |
| 63 | + uses: github/codeql-action/analyze@v2 |
0 commit comments