-
Notifications
You must be signed in to change notification settings - Fork 0
62 lines (52 loc) · 2.01 KB
/
codeql.yml
File metadata and controls
62 lines (52 loc) · 2.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
name: CodeQL
# CodeQL performs deep semantic analysis and requires a full build (~30 min).
# It runs weekly to catch newly published query findings against the existing
# codebase, not on every PR (too slow to be a useful gate).
on:
push:
branches: [ main, develop ]
paths:
- "AIUsageTracker.Core/**"
- "AIUsageTracker.Infrastructure/**"
- "AIUsageTracker.Monitor/**"
- "AIUsageTracker.Web/**"
- "AIUsageTracker.UI.Slim/**"
- "AIUsageTracker.CLI/**"
schedule:
- cron: "0 6 * * 3" # Wednesday at 6 AM
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
permissions:
contents: read
security-events: write
jobs:
analyze:
name: CodeQL Analysis (C#)
runs-on: ubuntu-latest
timeout-minutes: 30
steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6
with:
persist-credentials: false
- name: Setup .NET
uses: actions/setup-dotnet@c2fa09f4bde5ebb9d1777cf28262a3eb3db3ced7 # v5
with:
dotnet-version: "8.0.x"
- name: Initialize CodeQL
uses: github/codeql-action/init@95e58e9a2cdfd71adc6e0353d5c52f41a045d225 # v4.35.2
with:
languages: csharp
queries: security-and-quality
- name: Build cross-platform projects
run: |
dotnet build AIUsageTracker.Core/AIUsageTracker.Core.csproj --configuration Release
dotnet build AIUsageTracker.Infrastructure/AIUsageTracker.Infrastructure.csproj --configuration Release
dotnet build AIUsageTracker.Monitor/AIUsageTracker.Monitor.csproj --configuration Release
dotnet build AIUsageTracker.Web/AIUsageTracker.Web.csproj --configuration Release
dotnet build AIUsageTracker.CLI/AIUsageTracker.CLI.csproj --configuration Release
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@95e58e9a2cdfd71adc6e0353d5c52f41a045d225 # v4.35.2
with:
category: codeql-csharp