Skip to content

Commit

Permalink
Update SonarCloud job to use github action to install sonar-scanner and
Browse files Browse the repository at this point in the history
build-wrapper.

Signed-off-by: Christina Tempelaar-Lietz <[email protected]>
  • Loading branch information
xlietz committed May 24, 2023
1 parent a00bac5 commit c920e36
Show file tree
Hide file tree
Showing 2 changed files with 61 additions and 522 deletions.
29 changes: 19 additions & 10 deletions .github/workflows/analysis_workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,14 @@
name: Analysis

on:
schedule:
# schedule:
# Weekly Sunday build
- cron: "0 0 * * 0"
workflow_dispatch:
# - cron: "0 0 * * 0"
# workflow_dispatch:
#
pull_request:
branches:
- main

permissions:
contents: read
Expand Down Expand Up @@ -41,7 +45,11 @@ jobs:
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 50
# Disabling shallow clone is recommended for improving the
# relevancy of reporting
fetch-depth: 0
- name: Install sonar-scanner and build-wrapper
uses: sonarsource/sonarcloud-github-c-cpp@v1
- name: Create build directories
run: |
mkdir _install
Expand Down Expand Up @@ -88,6 +96,7 @@ jobs:
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
run: sonar-scanner -X -Dsonar.login=$SONAR_TOKEN


# ------------------------------------------------------------------------------
# Valgrind memcheck test
# ------------------------------------------------------------------------------
Expand Down Expand Up @@ -119,7 +128,7 @@ jobs:
shell: bash
- name: Install Dependencies
run: |
share/ci/scripts/linux/install_valgrind.sh
share/ci/scripts/linux/install_valgrind.sh
shell: bash
- name: Configure
run: |
Expand Down Expand Up @@ -171,12 +180,12 @@ jobs:
include:
# Fuzz test
- build: 1
build-descrip:
cflags:
cxxflags:
build-descrip:
cflags:
cxxflags:
# Fuzz with sanitizer
- build: 2
build-descrip: With Sanitizer
build-descrip: With Sanitizer
cflags: -DCFLAGS='-fsanitize=address'
cxxflags: -DCXXFLAGS='-fsanitize=address'
env:
Expand Down Expand Up @@ -208,7 +217,7 @@ jobs:
-DOPENEXR_RUN_FUZZ_TESTS='ON' \
-DOPENEXR_ENABLE_THREADING='ON' \
${{ matrix.cxxflags }} \
${{ matrix.cflags }}
${{ matrix.cflags }}
working-directory: _build
- name: Build
run: |
Expand Down
Loading

0 comments on commit c920e36

Please sign in to comment.