From c6fe6483e660264ff11bc4475fede51cb9f8a499 Mon Sep 17 00:00:00 2001 From: Reelix Date: Sun, 19 Nov 2023 01:04:24 +0200 Subject: [PATCH] Re-Fix CodeQL --- .github/workflows/codeql-analysis.yml | 44 ++++++++------------------- 1 file changed, 12 insertions(+), 32 deletions(-) diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml index 1649d32..29bfc30 100644 --- a/.github/workflows/codeql-analysis.yml +++ b/.github/workflows/codeql-analysis.yml @@ -1,16 +1,11 @@ -# For most projects, this workflow file will not need changing; you simply need -# to commit it to your repository. -# -# You may wish to alter this file to override the set of languages analyzed, -# or to provide custom queries or build logic. name: "CodeQL" on: push: - branches: [master] + branches: [ "main" ] pull_request: # The branches below must be a subset of the branches above - branches: [master] + branches: [ "main" ] schedule: - cron: '0 14 * * 0' @@ -18,30 +13,25 @@ jobs: analyze: name: Analyze runs-on: ubuntu-latest + permissions: + actions: read + contents: read + security-events: write strategy: fail-fast: false matrix: - # Override automatic language detection by changing the below list - # Supported options are ['csharp', 'cpp', 'go', 'java', 'javascript', 'python'] - language: ['csharp'] - # Learn more... - # https://docs.github.com/en/github/finding-security-vulnerabilities-and-errors-in-your-code/configuring-code-scanning#overriding-automatic-language-detection - + language: [ 'csharp' ] + steps: - name: Checkout repository uses: actions/checkout@v3 - with: - # We must fetch at least the immediate parents so that if this is - # a pull request then we can checkout the head. - fetch-depth: 2 - name: Install .NET Core uses: actions/setup-dotnet@v3 with: dotnet-version: '8.0.100' - - # Initializes the CodeQL tools for scanning. + - name: Initialize CodeQL uses: github/codeql-action/init@v2 with: @@ -49,18 +39,8 @@ jobs: - name: Autobuild uses: github/codeql-action/autobuild@v2 - - # ℹī¸ Command-line programs to run using the OS shell. - # 📚 https://git.io/JvXDl - - # ✏ī¸ If the Autobuild fails above, remove it and uncomment the following three lines - # and modify them (or add more) to build your code if your project - # uses a compiled language - - #- run: | - # make bootstrap - # make release - + - name: Perform CodeQL Analysis uses: github/codeql-action/analyze@v2 - + with: + category: "/language:${{matrix.language}}"