-
Notifications
You must be signed in to change notification settings - Fork 30
Expand file tree
/
Copy pathbuild.gradle
More file actions
79 lines (62 loc) · 2.11 KB
/
build.gradle
File metadata and controls
79 lines (62 loc) · 2.11 KB
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
plugins {
id('idea')
id('java')
id("io.freefair.lombok") version 'latest.release'
id("io.ebean") version "latest.release"
id("net.ltgt.errorprone") version "latest.release"
}
repositories {
mavenLocal()
mavenCentral()
}
java {
toolchain {
languageVersion = JavaLanguageVersion.of(17)
}
}
tasks.withType(JavaCompile).configureEach {
options.encoding = 'UTF-8'
options.compilerArgs.addAll(['-Xlint:all,-serial', '-parameters'])
options.release.set(17) // javac --release 7→8..22+
options.deprecation = true
options.debug = true
options.errorprone {
enabled = true
disableWarningsInGeneratedCode = true
excludedPaths = ".*/(generated|test).*/.*"
disable("UnusedVariable")
disable("MissingSummary")
errorproneArgs = ["-XepExcludedPaths:.*/test/.*"]
}
}
dependencies {
errorprone("com.google.errorprone:error_prone_core:latest.release")
implementation "com.google.code.findbugs:jsr305:latest.release" // https://javadoc.io/doc/com.google.code.findbugs/jsr305/latest/index.html
implementation "io.ebean:ebean:latest.release"
// apt query bean generation
annotationProcessor 'io.ebean:querybean-generator:latest.release'
testImplementation 'org.junit.jupiter:junit-jupiter:latest.release'
testImplementation 'io.ebean:ebean-test:latest.release'
testImplementation("ch.qos.logback:logback-classic:1.2.+")
testImplementation 'org.postgresql:postgresql:latest.release'
}
configurations.configureEach { // .implementation ? https://tomgregory.com/how-to-exclude-gradle-dependencies/
exclude group: 'io.ebean', module: 'ebean-joda-time'
exclude group: "commons-logging", module: "commons-logging" // spring?
exclude group: "org.apache.logging.log4j", module: "log4j-api"
exclude group: "org.apache.logging.log4j", module: "log4j-to-slf4j"
exclude group: "org.jboss.slf4j", module: "slf4j-jboss-logmanager"
exclude group: "com.mchange", module: "c3p0"
}
test {
useJUnitPlatform()
}
ebean {
debugLevel = 9 //0 - 9
queryBeans = true
}
lombok { version = "latest.release" }
test {
testLogging.showStandardStreams = true
testLogging.exceptionFormat = 'full'
}