From dc76959569b7053e0ae4b1e7b93087db8596ad7a Mon Sep 17 00:00:00 2001 From: Ashley <73482956+ascopes@users.noreply.github.com> Date: Sat, 30 Dec 2023 14:05:28 +0000 Subject: [PATCH] Create pipeline for codeql analysis --- .github/workflows/codeql.yml | 53 ++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 .github/workflows/codeql.yml diff --git a/.github/workflows/codeql.yml b/.github/workflows/codeql.yml new file mode 100644 index 00000000..0718d49c --- /dev/null +++ b/.github/workflows/codeql.yml @@ -0,0 +1,53 @@ +name: CodeQL analysis +on: + pull_request: + branches: + - main + types: + - opened + - synchronize + push: + branches: + - main + workflow_call: {} + workflow_dispatch: {} + +jobs: + codeql: + name: CodeQL analysis (${{ matrix.language }}) + runs-on: ubuntu-22.04 + + concurrency: + group: codeql-codeql-${{ github.head_ref || github.run_id }} + cancel-in-progress: true + + permissions: + actions: read + contents: read + security-events: write + + strategy: + fail-fast: false + matrix: + language: [ 'java' ] + + steps: + - name: Checkout repository + uses: actions/checkout@v4 + + # Initializes the CodeQL tools for scanning. + - name: Initialize CodeQL + # Do not freeze. Enables automatic updates to how CodeQL scans + uses: github/codeql-action/init@v3 + with: + languages: ${{ matrix.language }} + + - name: Autobuild + # Do not freeze. Enables automatic updates to how CodeQL scans + uses: github/codeql-action/autobuild@v3 + + - name: Perform CodeQL Analysis + # Do not freeze. Enables automatic updates to how CodeQL scans + uses: github/codeql-action/analyze@v3 + with: + category: "/language:${{matrix.language}}"