Skip to content

Commit

Permalink
swith to CI analysis mode for sonar
Browse files Browse the repository at this point in the history
  • Loading branch information
frs69wq committed May 24, 2024
1 parent a378e9b commit 0ae0cba
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 1 deletion.
18 changes: 17 additions & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,17 @@ concurrency:
jobs:
build:
runs-on: ubuntu-latest
env:
BUILD_WRAPPER_OUT_DIR: bw-outputs
steps:
- uses: actions/checkout@master

with:
fetch-depth: 0
- name: Install prereqs
run: |
sudo apt-get update
sudo apt-get install -y libgraphviz-dev libboost-all-dev
- name: Install SimGrid
run: |
git clone https://framagit.org/simgrid/simgrid.git
Expand All @@ -44,6 +48,18 @@ jobs:
run: |
sudo apt-get -y install lcov
- name: Install sonar-scanner and build-wrapper
uses: SonarSource/sonarcloud-github-c-cpp@v2
- name: Run build-wrapper
run: |
build-wrapper-linux-x86-64 --out-dir ${{ env.BUILD_WRAPPER_OUT_DIR }} make
- 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"
- name: Run tests, compute coverage
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
Expand Down
File renamed without changes.

0 comments on commit 0ae0cba

Please sign in to comment.