-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathbuild.gradle
64 lines (55 loc) · 1.68 KB
/
build.gradle
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
buildscript {
repositories {
jcenter()
}
dependencies {
classpath 'org.ajoberstar:grgit:1.1.0'
classpath "org.jfrog.buildinfo:build-info-extractor-gradle:4.7.3"
}
}
plugins {
id "org.sonarqube" version "2.8"
id "com.github.spotbugs" version "2.0.1"
id 'com.palantir.git-version' version '0.12.2'
}
version = gitVersion()
def v = versionDetails()
if(v.branchName =~ (/master|develop/)) {
version = "${v.branchName}.${version}"
}
allprojects {
repositories {
mavenLocal()
jcenter()
}
apply plugin: 'jacoco'
jacoco {
toolVersion = "0.8.4"
reportsDir = file("$buildDir/coverage")
}
project.afterEvaluate { Project p ->
if (p.tasks.findByName('jacocoTestReport')) {
jacocoTestReport.reports.xml.enabled(true)
jacocoTestReport.dependsOn = [test]
}
}
}
subprojects {
version = version
}
wrapper {
gradleVersion = '5.4.1'
}
sonarqube {
properties {
property "sonar.projectKey", "vbk:alt-integration"
property "sonar.projectName", "Alt Integration Service"
property "sonar.host.url", "https://sonar.veriblock.org"
property "sonar.java.binaries", "${project.projectDir}/build/classes"
property "sonar.java.libraries", "${project.projectDir}/build/libs"
property "sonar.java.test.binaries", "${project.projectDir}/build/test-results/test/binary"
property "sonar.junit.reportsPaths", "${project.projectDir}/build/test-results/**/*.xml"
property "sonar.jacoco.reportPaths", "${project.projectDir}/build/jacoco/test.exec"
property "sonar.exclusions", "**/generated/*.java"
}
}