forked from mapfish/mapfish-print
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
111 lines (94 loc) · 2.88 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
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
buildscript {
repositories {
mavenLocal()
jcenter()
maven {
url "https://plugins.gradle.org/m2/"
}
}
dependencies {
classpath "gradle.plugin.com.github.spotbugs.snom:spotbugs-gradle-plugin:4.7.5"
classpath "se.bjurr.violations:violations-gradle-plugin:1.51.0"
classpath 'org.owasp:dependency-check-gradle:7.1.0.1'
}
}
defaultTasks 'build'
wrapper {
gradleVersion = '5.5.1'
distributionType = Wrapper.DistributionType.ALL
}
allprojects {
group = 'org.mapfish.print'
version = '3.29.0-SNAPSHOT'
ext.spotbugsVersion = '4.6.0'
apply plugin: 'org.owasp.dependencycheck'
dependencyCheck {
outputDirectory = "security-report"
}
}
configurations.all {
resolutionStrategy {
force 'xml-apis:xml-apis:2.0.2'
}
}
apply plugin: 'org.owasp.dependencycheck'
configure(subprojects.findAll { ['core', 'examples'].contains(it.name) }) {
apply plugin: 'java'
apply plugin: 'com.github.spotbugs'
apply plugin: 'eclipse'
apply plugin: 'idea'
apply plugin: 'project-report'
apply plugin: 'checkstyle'
apply plugin: 'se.bjurr.violations.violations-gradle-plugin'
jar.dependsOn(checkstyleMain)
checkstyle {
toolVersion = "7.8.2"
configFile = file("$rootProject.rootDir/checkstyle_checks.xml")
configProperties = ['basedir': project.rootDir.path]
ignoreFailures = true
reportsDir = file("$project.buildDir/reports/checkstyleReports")
}
checkstyleTest.enabled = false
spotbugs {
toolVersion = "${project.spotbugsVersion}"
ignoreFailures = true
reportsDir = file("$project.buildDir/reports/spotbugsReports")
effort = "max"
reportLevel = "high"
}
spotbugsTest.enabled = false
task violations(type: se.bjurr.violations.gradle.plugin.ViolationsTask) {
minSeverity = 'INFO'
detailLevel = 'VERBOSE' // PER_FILE_COMPACT, COMPACT or VERBOSE
maxViolations = 0
printViolations = true
violations = [
["FINDBUGS", ".", ".*/reports/spotbugsReports/.*\\.xml", "Spotbugs"],
["CHECKSTYLE", ".", ".*/reports/checkstyleReports/.*\\.xml", "Checkstyle"]
]
}
check.finalizedBy violations
sourceCompatibility = 1.8
targetCompatibility = 1.8
compileJava.options.compilerArgs = ['-Xlint:deprecation', '-Xlint:unchecked']
dependencies {
testCompile(
"junit:junit:4.13.2",
'org.mockito:mockito-core:4.5.1',
)
}
test {
jvmArgs '-XX:+CMSClassUnloadingEnabled'
minHeapSize = "128m"
maxHeapSize = "512m"
testLogging {
exceptionFormat = 'full'
}
}
tasks.withType(JavaCompile) {
options.encoding = 'utf-8'
}
tasks.withType(Javadoc) {
options.encoding = 'utf-8'
}
}