From 95aebef9dd02676b3ea57f14e4e857505dfac500 Mon Sep 17 00:00:00 2001 From: Martin Costello Date: Sat, 27 Jul 2024 08:48:28 +0100 Subject: [PATCH] Remove build from CodeQL Analyse C# code without building it. --- .github/workflows/codeql-analysis.yml | 25 +++++++++---------------- 1 file changed, 9 insertions(+), 16 deletions(-) diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml index 30a94965c8..eb13163562 100644 --- a/.github/workflows/codeql-analysis.yml +++ b/.github/workflows/codeql-analysis.yml @@ -2,9 +2,14 @@ name: code-scan on: push: - branches: [ main, release/* ] + branches: + - main + - release/* pull_request: - branches: [ main, release/* ] + branches: + - main + - release/* + - dotnet-vnext schedule: - cron: '0 8 * * MON' workflow_dispatch: @@ -30,25 +35,13 @@ jobs: - name: Checkout repository uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7 - - name: Setup .NET SDK - uses: actions/setup-dotnet@6bd8b7f7774af54e05809fcc5431931b3eb1ddee # v4.0.1 - - - name: Setup NuGet cache - uses: actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4.0.2 - with: - path: ~/.nuget/packages - key: ${{ runner.os }}-nuget-${{ hashFiles('**/*.csproj', '**/*.props') }} - restore-keys: ${{ runner.os }}-nuget- - - name: Initialize CodeQL uses: github/codeql-action/init@5cf07d8b700b67e235fbb65cbc84f69c0cf10464 # v3.25.14 with: + build-mode: none languages: ${{ matrix.language }} - - name: Autobuild - uses: github/codeql-action/autobuild@5cf07d8b700b67e235fbb65cbc84f69c0cf10464 # v3.25.14 - - name: Perform CodeQL Analysis uses: github/codeql-action/analyze@5cf07d8b700b67e235fbb65cbc84f69c0cf10464 # v3.25.14 with: - category: "/language:${{ matrix.language }}" + category: '/language:${{ matrix.language }}'