Skip to content

Commit

Permalink
Add CodeQL GitHub Action
Browse files Browse the repository at this point in the history
  • Loading branch information
walbourn committed Jul 25, 2024
1 parent a72edfd commit b22850d
Show file tree
Hide file tree
Showing 9 changed files with 74 additions and 2 deletions.
59 changes: 59 additions & 0 deletions .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT License.
#
# http://go.microsoft.com/fwlink/?LinkID=512686

name: "CodeQL"

on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
paths-ignore:
- '*.md'
- LICENSE
- '.nuget/*'
- build/*.mdb
- build/*.props
- build/*.ps1
- build/*.yml
schedule:
- cron: '34 18 * * 6'

jobs:
analyze:
name: Analyze (C/C++)
runs-on: windows-latest
timeout-minutes: 360
permissions:
security-events: write
packages: read

steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: 'Install Ninja'
run: choco install ninja

- uses: ilammy/msvc-dev-cmd@v1

- name: Initialize CodeQL
uses: github/codeql-action/init@v3
with:
languages: c-cpp
build-mode: manual

- name: 'Configure CMake'
working-directory: ${{env.GITHUB_WORKSPACE}}
run: cmake --preset=x64-Debug

- name: 'Build'
working-directory: ${{env.GITHUB_WORKSPACE}}
run: cmake --build out\build\x64-Debug

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3
with:
category: "/language:c-cpp"
3 changes: 1 addition & 2 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,9 @@ on:
- '*.md'
- LICENSE
- '.nuget/*'
- build/*.cmd
- build/*.mdb
- build/*.props
- build/*.ps1
- build/*.targets
- build/*.yml

jobs:
Expand Down
2 changes: 2 additions & 0 deletions build/UVAtlas-GitHub-CMake-Dev17.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ trigger:
exclude:
- '*.md'
- LICENSE
- '.github/*'
- '.nuget/*'
- build/*.mdb
- build/*.ps1
Expand All @@ -32,6 +33,7 @@ pr:
exclude:
- '*.md'
- LICENSE
- '.github/*'
- '.nuget/*'
- build/*.mdb
- build/*.ps1
Expand Down
2 changes: 2 additions & 0 deletions build/UVAtlas-GitHub-CMake.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ trigger:
exclude:
- '*.md'
- LICENSE
- '.github/*'
- '.nuget/*'
- build/*.mdb
- build/*.ps1
Expand All @@ -32,6 +33,7 @@ pr:
exclude:
- '*.md'
- LICENSE
- '.github/*'
- '.nuget/*'
- build/*.mdb
- build/*.ps1
Expand Down
2 changes: 2 additions & 0 deletions build/UVAtlas-GitHub-Dev17.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ trigger:
- '*.md'
- LICENSE
- CMake*
- '.github/*'
- '.nuget/*'
- build/*.cmake
- build/*.in
Expand All @@ -36,6 +37,7 @@ pr:
- '*.md'
- LICENSE
- CMake*
- '.github/*'
- '.nuget/*'
- build/*.cmake
- build/*.in
Expand Down
2 changes: 2 additions & 0 deletions build/UVAtlas-GitHub-MinGW.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ trigger:
exclude:
- '*.md'
- LICENSE
- '.github/*'
- '.nuget/*'
- build/*.mdb
- build/*.ps1
Expand All @@ -32,6 +33,7 @@ pr:
exclude:
- '*.md'
- LICENSE
- '.github/*'
- '.nuget/*'
- build/*.mdb
- build/*.ps1
Expand Down
2 changes: 2 additions & 0 deletions build/UVAtlas-GitHub-Test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ trigger:
- '*.md'
- LICENSE
- CMake*
- '.github/*'
- '.nuget/*'
- build/*.cmake
- build/*.in
Expand All @@ -36,6 +37,7 @@ pr:
- '*.md'
- LICENSE
- CMake*
- '.github/*'
- '.nuget/*'
- build/*.cmake
- build/*.in
Expand Down
2 changes: 2 additions & 0 deletions build/UVAtlas-GitHub-WSL.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ trigger:
exclude:
- '*.md'
- LICENSE
- '.github/*'
- '.nuget/*'
- build/*.mdb
- build/*.ps1
Expand All @@ -32,6 +33,7 @@ pr:
exclude:
- '*.md'
- LICENSE
- '.github/*'
- '.nuget/*'
- build/*.mdb
- build/*.ps1
Expand Down
2 changes: 2 additions & 0 deletions build/UVAtlas-GitHub.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ trigger:
- '*.md'
- LICENSE
- CMake*
- '.github/*'
- '.nuget/*'
- build/*.cmake
- build/*.in
Expand All @@ -36,6 +37,7 @@ pr:
- '*.md'
- LICENSE
- CMake*
- '.github/*'
- '.nuget/*'
- build/*.cmake
- build/*.in
Expand Down

0 comments on commit b22850d

Please sign in to comment.