From a56fcf4708cfae2ee87942c3a490ed64b972cf3b Mon Sep 17 00:00:00 2001 From: Sandro Hanea Date: Sat, 15 Feb 2025 18:44:41 +0100 Subject: [PATCH] Added codeql with dotnet build --- .github/workflows/build-all.yml | 2 ++ .github/workflows/dotnet.yml | 14 +++++++++++++- 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build-all.yml b/.github/workflows/build-all.yml index 196cbbb8..0af4a797 100644 --- a/.github/workflows/build-all.yml +++ b/.github/workflows/build-all.yml @@ -17,6 +17,8 @@ on: description: 'Enable GPU libraries build and publish' required: true default: 'false' + schedule: + - cron: '40 17 * * 0' jobs: android: diff --git a/.github/workflows/dotnet.yml b/.github/workflows/dotnet.yml index 6b0fe901..f3d8da38 100755 --- a/.github/workflows/dotnet.yml +++ b/.github/workflows/dotnet.yml @@ -37,7 +37,14 @@ jobs: - name: Restore dependencies run: dotnet restore ./Whisper.net.sln - + + # Initializes the CodeQL tools for scanning. + - name: Initialize CodeQL + uses: github/codeql-action/init@v3 + with: + languages: csharp + build-mode: manual + - name: Build run: dotnet build ./Whisper.net.sln --no-restore -warnaserror @@ -53,6 +60,11 @@ jobs: path: ./**/*.trx reporter: dotnet-trx + - name: Perform CodeQL Analysis + uses: github/codeql-action/analyze@v3 + with: + category: "/language:csharp" + - name: Upload trx files uses: actions/upload-artifact@v4 if: success() || failure() # run this step even if previous step failed