Skip to content

Commit

Permalink
switch to the sonar cloud action
Browse files Browse the repository at this point in the history
  • Loading branch information
cescoffier committed Nov 17, 2019
1 parent 2663500 commit b603740
Show file tree
Hide file tree
Showing 3 changed files with 41 additions and 5 deletions.
16 changes: 11 additions & 5 deletions .github/workflows/build.yml → .github/workflows/build-master.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
name: Continuous Integration Build

on: [push, pull_request]
on:
push:
branches:
- master

jobs:
build_java8:
Expand Down Expand Up @@ -34,10 +37,13 @@ jobs:
uses: actions/setup-java@v1
with:
java-version: 1.8
- name: Sonar analysis
env:
SONAR_LOGIN: ${{ secrets.SONAR_LOGIN }}
- name: Coverage
run: |
mvn verify sonar:sonar -Pcoverage -Dsonar.projectKey=smallrye_smallrye-reactive-messaging -Dsonar.projectName="SmallRye Reactive Messaging" -Dsonar.organization=smallrye -Dsonar.host.url=https://sonarcloud.io -Dsonar.login=$SONAR_LOGIN
mvn verify -Pcoverage
- name: Sonar Scan
uses: sonarsource/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_LOGIN }}


26 changes: 26 additions & 0 deletions .github/workflows/build-pull.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Pull Request Build

on: pull_request

jobs:
build_java8:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- name: Install JDK 1.8
uses: actions/setup-java@v1
with:
java-version: 1.8
- name: Build with Maven
run: mvn -B clean install --file pom.xml

build_java11:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- name: Install JDK 11
uses: actions/setup-java@v1
with:
java-version: 11
- name: Build with Maven
run: mvn -B clean install --file pom.xml
4 changes: 4 additions & 0 deletions sonar-project.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
sonar.organization=smallrye
sonar.projectKey=smallrye_smallrye-reactive-messaging
sonar.host.url=https://sonarcloud.io
sonar.sources=.

0 comments on commit b603740

Please sign in to comment.