This repository was archived by the owner on Nov 10, 2017. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
96 lines (80 loc) · 2.37 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
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
buildscript {
repositories {
mavenCentral()
jcenter()
}
dependencies {
classpath("org.springframework.boot:spring-boot-gradle-plugin:${springBootVersion}")
classpath("org.standardout:gradle-versioneye-plugin:${versioneyeVersion}")
}
}
apply plugin: 'java'
apply plugin: 'eclipse'
apply plugin: 'org.springframework.boot'
apply plugin: 'idea'
apply plugin: 'org.standardout.versioneye'
apply plugin: 'io.spring.dependency-management'
apply plugin: "findbugs"
apply plugin: "pmd"
apply plugin: 'checkstyle'
apply plugin: 'groovy'
apply plugin: "jacoco"
jar {
baseName = 'dreg-heap-backend'
version = '0.0.1-SNAPSHOT'
}
sourceCompatibility = 1.8
repositories {
mavenCentral()
}
dependencies {
compile("org.springframework.boot:spring-boot-starter-web") {
exclude module: "spring-boot-starter-tomcat"
}
compile("org.springframework.boot:spring-boot-starter-jetty")
compile('org.springframework.boot:spring-boot-starter')
compile('org.springframework.boot:spring-boot-starter-web')
testCompile('org.springframework.boot:spring-boot-starter-test')
compile("org.codehaus.groovy:groovy-all:${groovyVersion}")
}
findbugs {
toolVersion = "${findbugsVersion}"
ignoreFailures = true
sourceSets = [sourceSets.main]
reportsDir = file("$project.buildDir/reports/findbugs")
effort = "max"
}
pmd {
toolVersion = "${pmdVersion}"
ignoreFailures = true
sourceSets = [sourceSets.main]
reportsDir = file("$project.buildDir/reports/pmd")
ruleSets = ["java-basic", "java-strings", "java-braces"]
}
checkstyle {
toolVersion = "${checkstyleVersion}"
configFile = new File(rootDir, "build-tools/quality/config/chekstyle/checkstyle.xml")
}
check << {
File outDir = new File('build/reports/pmd/')
outDir.mkdirs()
ant.taskdef(name: 'cpd', classname: 'net.sourceforge.pmd.cpd.CPDTask',
classpath: configurations.pmd.asPath)
ant.cpd(minimumTokenCount: '100', format: 'xml',
outputFile: new File(outDir, 'cpd.xml')) {
fileset(dir: "src/main/java") {
include(name: '**/*.java')
}
}
}
jacoco {
toolVersion = "${jacocoVersion}"
reportsDir = file("$buildDir/customJacocoReportDir")
}
jacocoTestReport {
reports {
xml.enabled false
csv.enabled false
html.destination "${buildDir}/jacocoHtml"
}
}