CodeQL analysis #281
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CodeQL analysis | |
on: | |
pull_request: | |
branches: | |
- master | |
schedule: | |
- cron: "0 7 * * 0" | |
jobs: | |
analyze: | |
name: Analyze with CodeQL | |
runs-on: ubuntu-latest | |
timeout-minutes: 15 | |
env: | |
DOTNET_CLI_TELEMETRY_OPTOUT: 1 | |
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 1 | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v3 | |
- name: Initialize CodeQL | |
uses: github/codeql-action/init@v1 | |
with: | |
languages: csharp | |
- name: Cache NuGet packages | |
uses: actions/cache@v3.0.1 | |
with: | |
path: ~/.nuget/packages # Mac/Linux | |
key: ${{ hashFiles('*/packages.lock.json') }} | |
- name: Setup .NET Core SDK | |
uses: actions/setup-dotnet@v2 | |
with: | |
dotnet-version: 2.2.x | |
- name: Build solution | |
run: dotnet build /p:UseSharedCompilation=false | |
- name: Perform CodeQL analysis | |
uses: github/codeql-action/analyze@v1 |