-
Notifications
You must be signed in to change notification settings - Fork 74
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add CodeQL code scanning and fix several identified issues (#354)
* initial CodeQL workflow file * fix several CodeQL issues * fix another CodeQL issue * disable automatic creation of SPIR-V files for now * more attempts to validate that the home directory is a valid directory * add a call to realpath to validate that the home directory is valid * cleanup
- Loading branch information
Showing
7 changed files
with
83 additions
and
102 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
name: analyze | ||
|
||
permissions: | ||
contents: read | ||
|
||
on: | ||
push: | ||
paths-ignore: | ||
- '**/*.md' | ||
pull_request: | ||
paths-ignore: | ||
- '**/*.md' | ||
branches: | ||
- main | ||
|
||
env: | ||
BUILD_TYPE: RelWithDebInfo | ||
|
||
jobs: | ||
analyze: | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: [ubuntu-latest, windows-latest] | ||
|
||
runs-on: ${{matrix.os}} | ||
|
||
permissions: | ||
security-events: write | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Initialize CodeQL | ||
uses: github/codeql-action/init@v3 | ||
with: | ||
languages: cpp | ||
|
||
- name: Create Build Directory | ||
run: cmake -E make_directory ${{runner.workspace}}/build | ||
|
||
- name: Run CMake | ||
shell: bash | ||
working-directory: ${{runner.workspace}}/build | ||
run: cmake -DENABLE_CLILOADER=1 -DCMAKE_BUILD_TYPE=$BUILD_TYPE $GITHUB_WORKSPACE | ||
|
||
- name: Build | ||
working-directory: ${{runner.workspace}}/build | ||
shell: bash | ||
run: cmake --build . --parallel 4 --config $BUILD_TYPE | ||
|
||
- name: Perform CodeQL Analysis | ||
uses: github/codeql-action/analyze@v3 |
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
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
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
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
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
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