Refactor complex sentry function #723
Workflow file for this run
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: Sonarcloud Analysis | |
on: | |
schedule: | |
- cron: '21 9 * * 4' | |
push: | |
branches: | |
- 'master' | |
pull_request: | |
# Declare default permissions as read only. | |
permissions: read-all | |
jobs: | |
sonarcloud: | |
runs-on: ubuntu-latest | |
container: egecetinn/ubuntu2204 | |
env: | |
BUILD_WRAPPER_OUT_DIR: build/sonar | |
steps: | |
- name: Checkout Code | |
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
with: | |
fetch-depth: 0 | |
submodules: recursive | |
- name: Prepare | |
run: git config --global --add safe.directory "$GITHUB_WORKSPACE" | |
- name: Install Test Requirements | |
run: pip install -r tests/data/requirements.txt | |
- name: Install sonar-scanner and build-wrapper | |
uses: sonarsource/sonarcloud-github-c-cpp@816b1822d71776ee0d32bc012e95024ec52ac1fc # v3.1.0 | |
- name: Configure | |
run: cmake -S . -B build -DCMAKE_BUILD_TYPE=Debug -DXXX_ENABLE_COVERAGE=ON | |
- name: Run build-wrapper | |
run: build-wrapper-linux-x86-64 --out-dir ${{ env.BUILD_WRAPPER_OUT_DIR }} cmake --build build/ --config Debug --parallel --target coverage-xml | |
- name: Run sonar-scanner | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} | |
run: sonar-scanner --define sonar.cfamily.compile-commands="${{ env.BUILD_WRAPPER_OUT_DIR }}/compile_commands.json" --define sonar.coverageReportPaths=./build/coverage-xml-sonar.xml |