52 lines
1.3 KiB
Groovy
52 lines
1.3 KiB
Groovy
//file:noinspection GrUnresolvedAccess
|
|
apply plugin: 'java'
|
|
apply plugin: 'java-library'
|
|
apply plugin: 'jacoco'
|
|
apply from: rootDir.toPath().resolve('libs.gradle').toFile()
|
|
|
|
String getProperty1(String propertyName1, String propertyName2) {
|
|
return (String) (project.hasProperty(propertyName1) ? project.property(propertyName1) : project.property(propertyName2))
|
|
}
|
|
|
|
project.group = getProperty1('module.group', 'prj.group')
|
|
project.version = getProperty1('module.version', 'prj.version')
|
|
jar.archiveBaseName.set(getProperty1('module.name', 'prj.name'))
|
|
|
|
compileJava {
|
|
sourceCompatibility = targetCompatibility = JavaVersion.VERSION_11
|
|
options.encoding = 'UTF-8'
|
|
}
|
|
|
|
repositories {
|
|
mavenLocal()
|
|
mavenCentral()
|
|
}
|
|
|
|
dependencies {
|
|
annotationProcessor libs.lombok
|
|
compileOnly libs.lombok
|
|
compileOnly libs.annotations
|
|
|
|
implementation libs.logger.slf4j
|
|
|
|
implementation libs.dagger2.implementation
|
|
annotationProcessor libs.dagger2.annotationProcessor
|
|
|
|
testAnnotationProcessor libs.lombok
|
|
testCompileOnly libs.lombok
|
|
|
|
testImplementation libs.test.junit5.api
|
|
testImplementation libs.test.junit5.params
|
|
testRuntimeOnly libs.test.junit5.engine
|
|
|
|
testRuntimeOnly libs.test.logger
|
|
}
|
|
|
|
test {
|
|
useJUnitPlatform()
|
|
}
|
|
|
|
jacoco {
|
|
toolVersion = '0.8.7'
|
|
}
|