Add accessor to fields of implementation row descriptor (IRD) (#342) #154
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
--- | |
# GHA workflow to run Static Analysis and submit results to GitHub Code Scanning Alerts | |
name: "Analysis" | |
on: | |
push: | |
branches: | |
- main | |
paths: | |
- '**.cpp' | |
- '**.h' | |
- '.github/workflows/analysis.yml' | |
pull_request: | |
paths: | |
- '**.cpp' | |
- '**.h' | |
- '.github/workflows/analysis.yml' | |
env: | |
build: '${{ github.workspace }}/build' | |
config: 'Debug' | |
jobs: | |
core: | |
name: CppCoreCheckRules | |
runs-on: windows-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v3 | |
- name: Configure CMake | |
run: cmake -B ${{ env.build }} -DCMAKE_BUILD_TYPE=${{ env.config }} | |
- name: Run MSVC Code Analysis | |
uses: microsoft/msvc-code-analysis-action@v0.1.1 | |
# Provide a unique ID to access the sarif output path | |
id: run-core-analysis | |
with: | |
cmakeBuildDirectory: ${{ env.build }} | |
buildConfiguration: ${{ env.config }} | |
# Ruleset file that will determine what checks will be run | |
ruleset: CppCoreCheckRules.ruleset | |
# Paths to ignore analysis of CMake targets and includes | |
ignoredPaths: ${{ github.workspace }}/test/catch | |
# Upload SARIF file to GitHub Code Scanning Alerts | |
- name: Upload SARIF to GitHub | |
uses: github/codeql-action/upload-sarif@v3 | |
with: | |
sarif_file: ${{ steps.run-core-analysis.outputs.sarif }} | |
# Upload SARIF file as an Artifact to download and view | |
- name: Upload SARIF as an Artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: sarif-file | |
path: ${{ steps.run-core-analysis.outputs.sarif }} | |
overwrite: true | |
native: | |
name: NativeRecommendedRules | |
runs-on: windows-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v3 | |
- name: Configure CMake | |
run: cmake -B ${{ env.build }} -DCMAKE_BUILD_TYPE=${{ env.config }} | |
- name: Run MSVC Code Analysis | |
uses: microsoft/msvc-code-analysis-action@v0.1.1 | |
# Provide a unique ID to access the sarif output path | |
id: run-native-analysis | |
with: | |
cmakeBuildDirectory: ${{ env.build }} | |
buildConfiguration: ${{ env.config }} | |
# Ruleset file that will determine what checks will be run | |
ruleset: NativeRecommendedRules.ruleset | |
# Paths to ignore analysis of CMake targets and includes | |
ignoredPaths: ${{ github.workspace }}/test/catch | |
# Upload SARIF file to GitHub Code Scanning Alerts | |
- name: Upload SARIF to GitHub | |
uses: github/codeql-action/upload-sarif@v3 | |
with: | |
sarif_file: ${{ steps.run-native-analysis.outputs.sarif }} | |
# Upload SARIF file as an Artifact to download and view | |
- name: Upload SARIF as an Artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: sarif-file | |
path: ${{ steps.run-native-analysis.outputs.sarif }} | |
overwrite: true | |
flawfinder: | |
name: Flawfinder | |
runs-on: ubuntu-latest | |
permissions: | |
actions: read | |
contents: read | |
security-events: write | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- name: flawfinder_scan | |
uses: david-a-wheeler/flawfinder@8e4a779ad59dbfaee5da586aa9210853b701959c | |
with: | |
arguments: '--sarif ./' | |
output: 'flawfinder_results.sarif' | |
- name: Upload analysis results to GitHub Security tab | |
uses: github/codeql-action/upload-sarif@v3 | |
with: | |
sarif_file: ${{github.workspace}}/flawfinder_results.sarif |