Allow to change default sonar version in bzlmod #21
Workflow file for this run
This file contains hidden or 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: CI | |
| # Controls when the action will run. | |
| on: | |
| push: | |
| branches: [master] | |
| pull_request: | |
| workflow_dispatch: | |
| concurrency: | |
| # Cancel previous actions from the same PR: https://stackoverflow.com/a/72408109 | |
| group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v5 | |
| - uses: bazel-contrib/[email protected] | |
| - name: bazel build | |
| run: | | |
| bazel build //:sonar_scanner | |
| bazel build //:sonarqube_coverage_generator | |
| # TODO Building //docs:docs has missing dependencies to rules_java | |
| # and it is failing | |
| # - name: bazel aquery | |
| # run: | | |
| # bazel aquery ... | |
| test-workspace: | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| folder: | |
| - examples/java-workspace | |
| - examples/java-bzlmod | |
| steps: | |
| - uses: actions/checkout@v5 | |
| - uses: bazel-contrib/[email protected] | |
| - name: bazel test coverage | |
| working-directory: ${{ matrix.folder }} | |
| run: | | |
| bazel coverage //... | |
| bazel build //:sonarqube | |
| - name: bazel sonarqube report | |
| working-directory: ${{ matrix.folder }} | |
| # TODO We don't have sonar server to send scan results | |
| continue-on-error: True | |
| run: | | |
| bazel run //:sonarqube | |