mirror of
https://github.com/BentoBoxWorld/Limits.git
synced 2024-11-23 19:16:38 +01:00
Added SonarCloud
This commit is contained in:
parent
fc471a2bee
commit
b24e76ec67
1
.gitignore
vendored
1
.gitignore
vendored
@ -84,3 +84,4 @@ nbdist/
|
||||
nbactions.xml
|
||||
nb-configuration.xml
|
||||
.nb-gradle/
|
||||
/.idea/
|
||||
|
24
.travis.yml
Normal file
24
.travis.yml
Normal file
@ -0,0 +1,24 @@
|
||||
language: java
|
||||
sudo: false
|
||||
addons:
|
||||
sonarcloud:
|
||||
organization: "bentobox-world"
|
||||
token:
|
||||
secure: $SONAR_TOKEN
|
||||
|
||||
jdk:
|
||||
- openjdk8
|
||||
- openjdk11
|
||||
|
||||
matrix:
|
||||
allow_failures:
|
||||
- jdk: openjdk11
|
||||
|
||||
script:
|
||||
# the following command line builds the project, runs the tests with coverage and then execute the SonarCloud analysis
|
||||
- mvn clean org.jacoco:jacoco-maven-plugin:prepare-agent install sonar:sonar -Dsonar.projectKey=BentoBoxWorld_Limits
|
||||
|
||||
cache:
|
||||
directories:
|
||||
- '$HOME/.m2/repository'
|
||||
- '$HOME/.sonar/cache'
|
31
pom.xml
31
pom.xml
@ -95,6 +95,30 @@
|
||||
<build.number></build.number>
|
||||
</properties>
|
||||
</profile>
|
||||
<profile>
|
||||
<id>sonar</id>
|
||||
<properties>
|
||||
<sonar.host.url>https://sonarcloud.io</sonar.host.url>
|
||||
<sonar.organization>bentobox-world</sonar.organization>
|
||||
</properties>
|
||||
<build>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.sonarsource.scanner.maven</groupId>
|
||||
<artifactId>sonar-maven-plugin</artifactId>
|
||||
<version>3.6.0.1398</version>
|
||||
<executions>
|
||||
<execution>
|
||||
<phase>verify</phase>
|
||||
<goals>
|
||||
<goal>sonar</goal>
|
||||
</goals>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
</profile>
|
||||
</profiles>
|
||||
|
||||
<repositories>
|
||||
@ -213,9 +237,14 @@
|
||||
<plugin>
|
||||
<groupId>org.jacoco</groupId>
|
||||
<artifactId>jacoco-maven-plugin</artifactId>
|
||||
<version>0.8.1</version>
|
||||
<version>0.8.3</version>
|
||||
<configuration>
|
||||
<append>true</append>
|
||||
<excludes>
|
||||
<!-- This is required to prevent Jacoco from adding
|
||||
synthetic fields to a JavaBean class (causes errors in testing) -->
|
||||
<exclude>**/*Names*</exclude>
|
||||
</excludes>
|
||||
</configuration>
|
||||
<executions>
|
||||
<execution>
|
||||
|
Loading…
Reference in New Issue
Block a user