diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml index 84117ddd..8e84d81c 100644 --- a/.github/workflows/codeql-analysis.yml +++ b/.github/workflows/codeql-analysis.yml @@ -2,34 +2,40 @@ name: "CodeQL" on: push: - branches: [ main ] + branches: [ "main" ] pull_request: - branches: [ main ] + branches: [ "main" ] schedule: - - cron: '0 7 * * 6' + - cron: '18 19 * * 5' jobs: analyze: concurrency: group: ${{ github.workflow }}-${{ github.ref }} cancel-in-progress: true - name: Analyze + name: Analyze (${{ matrix.language }}) runs-on: ubuntu-latest + timeout-minutes: 360 permissions: - contents: read + # required for all workflows security-events: write + # required to fetch internal or private CodeQL packs + packages: read + + # only required for workflows in private repositories + actions: read + contents: read + strategy: fail-fast: false matrix: - language: ['java'] - + include: + - language: java-kotlin + build-mode: none # This mode only analyzes Java. Set this to 'autobuild' or 'manual' to analyze Kotlin too. steps: - name: Checkout repository uses: actions/checkout@v4 - with: - fetch-depth: 2 - - uses: actions/setup-java@v4 with: distribution: 'temurin' @@ -42,9 +48,10 @@ jobs: uses: github/codeql-action/init@v3 with: languages: ${{ matrix.language }} - - - name: Autobuild - uses: github/codeql-action/autobuild@v3 + build-mode: ${{ matrix.build-mode }} + queries: security-extended,security-and-quality - name: Perform CodeQL Analysis uses: github/codeql-action/analyze@v3 + with: + category: "/language:${{matrix.language}}"