2021-04-17 19:55:00 -04:00
|
|
|
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
|
|
|
|
|
2021-03-23 18:32:21 -04:00
|
|
|
group = "dev.fyloz.colorrecipesexplorer"
|
2020-10-08 23:14:43 -04:00
|
|
|
|
|
|
|
plugins {
|
|
|
|
id("java")
|
2021-03-09 15:12:28 -05:00
|
|
|
id("org.jetbrains.kotlin.jvm") version "1.4.30"
|
|
|
|
id("org.jetbrains.dokka") version "1.4.20"
|
2020-10-08 23:14:43 -04:00
|
|
|
id("org.springframework.boot") version "2.3.4.RELEASE"
|
2021-03-09 15:12:28 -05:00
|
|
|
id("org.jetbrains.kotlin.plugin.spring") version "1.4.30"
|
|
|
|
id("org.jetbrains.kotlin.plugin.jpa") version "1.4.30"
|
2020-10-08 23:14:43 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
repositories {
|
2021-03-09 15:12:28 -05:00
|
|
|
jcenter()
|
2020-10-08 23:14:43 -04:00
|
|
|
mavenCentral()
|
2021-03-04 17:26:26 -05:00
|
|
|
|
|
|
|
maven {
|
|
|
|
url = uri("https://git.fyloz.dev/api/v4/projects/40/packages/maven")
|
|
|
|
}
|
2020-10-08 23:14:43 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
dependencies {
|
2020-11-17 14:53:02 -05:00
|
|
|
implementation(platform("org.jetbrains.kotlin:kotlin-bom:1.4.10"))
|
|
|
|
implementation("org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.4.10")
|
|
|
|
implementation("org.jetbrains.kotlin:kotlin-reflect:1.4.10")
|
2020-10-08 23:14:43 -04:00
|
|
|
implementation("com.fasterxml.jackson.module:jackson-module-kotlin:2.11.3")
|
2020-11-17 14:53:02 -05:00
|
|
|
implementation("javax.xml.bind:jaxb-api:2.3.0")
|
|
|
|
implementation("io.jsonwebtoken:jjwt:0.9.1")
|
|
|
|
implementation("org.apache.poi:poi-ooxml:4.1.0")
|
|
|
|
implementation("org.apache.pdfbox:pdfbox:2.0.4")
|
2021-03-23 18:32:21 -04:00
|
|
|
implementation("dev.fyloz.colorrecipesexplorer:database-manager:1.2.0")
|
2020-10-08 23:14:43 -04:00
|
|
|
|
2020-10-15 23:38:13 -04:00
|
|
|
implementation("org.springframework.boot:spring-boot-starter-data-jpa:2.3.4.RELEASE")
|
|
|
|
implementation("org.springframework.boot:spring-boot-starter-jdbc:2.3.4.RELEASE")
|
|
|
|
implementation("org.springframework.boot:spring-boot-starter-web:2.3.4.RELEASE")
|
|
|
|
implementation("org.springframework.boot:spring-boot-starter-validation:2.3.4.RELEASE")
|
|
|
|
implementation("org.springframework.boot:spring-boot-starter-security:2.3.4.RELEASE")
|
|
|
|
implementation("org.springframework.boot:spring-boot-configuration-processor:2.3.4.RELEASE")
|
2020-11-17 14:53:02 -05:00
|
|
|
implementation("org.springframework.boot:spring-boot-devtools:2.3.4.RELEASE")
|
2020-10-15 23:38:13 -04:00
|
|
|
|
2020-11-17 14:53:02 -05:00
|
|
|
testImplementation("org.springframework:spring-test:5.1.6.RELEASE")
|
2021-04-26 23:30:46 -04:00
|
|
|
testImplementation("org.mockito:mockito-inline:3.6.0")
|
2020-11-17 14:53:02 -05:00
|
|
|
testImplementation("com.nhaarman.mockitokotlin2:mockito-kotlin:2.2.0")
|
|
|
|
testImplementation("org.junit.jupiter:junit-jupiter-api:5.3.2")
|
2021-04-26 23:30:46 -04:00
|
|
|
testImplementation("io.mockk:mockk:1.10.6")
|
2020-10-15 23:38:13 -04:00
|
|
|
testImplementation("org.springframework.boot:spring-boot-starter-test:2.3.4.RELEASE")
|
|
|
|
testImplementation("org.springframework.boot:spring-boot-test-autoconfigure:2.3.4.RELEASE")
|
2020-11-17 14:53:02 -05:00
|
|
|
testImplementation("org.jetbrains.kotlin:kotlin-test:1.4.10")
|
|
|
|
testImplementation("org.jetbrains.kotlin:kotlin-test-junit:1.4.10")
|
2020-10-08 23:14:43 -04:00
|
|
|
|
|
|
|
runtimeOnly("com.h2database:h2:1.4.199")
|
2020-12-23 14:45:21 -05:00
|
|
|
runtimeOnly("mysql:mysql-connector-java:8.0.22")
|
2021-03-04 17:26:26 -05:00
|
|
|
runtimeOnly("org.postgresql:postgresql:42.2.16")
|
|
|
|
runtimeOnly("com.microsoft.sqlserver:mssql-jdbc:9.2.1.jre11")
|
2020-10-08 23:14:43 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
java {
|
2021-02-11 13:32:22 -05:00
|
|
|
sourceCompatibility = JavaVersion.VERSION_11
|
|
|
|
targetCompatibility = JavaVersion.VERSION_11
|
2020-11-17 14:53:02 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
sourceSets {
|
|
|
|
main {
|
|
|
|
java
|
|
|
|
kotlin
|
|
|
|
}
|
|
|
|
test {
|
|
|
|
kotlin
|
|
|
|
}
|
2020-10-08 23:14:43 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
tasks.test {
|
2021-02-14 01:06:52 -05:00
|
|
|
reports {
|
|
|
|
junitXml.isEnabled = true
|
|
|
|
html.isEnabled = false
|
|
|
|
}
|
|
|
|
|
2020-10-08 23:14:43 -04:00
|
|
|
useJUnitPlatform()
|
|
|
|
testLogging {
|
2021-03-08 13:56:59 -05:00
|
|
|
events("skipped", "failed")
|
2020-10-08 23:14:43 -04:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2021-04-17 19:55:00 -04:00
|
|
|
tasks.withType<JavaCompile>() {
|
2021-02-11 13:32:22 -05:00
|
|
|
options.compilerArgs.addAll(arrayOf("--release", "11"))
|
2020-10-08 23:14:43 -04:00
|
|
|
}
|
2021-04-17 19:55:00 -04:00
|
|
|
tasks.withType<KotlinCompile>().all {
|
2021-03-09 14:08:57 -05:00
|
|
|
kotlinOptions {
|
2021-04-17 19:55:00 -04:00
|
|
|
jvmTarget = JavaVersion.VERSION_11.toString()
|
2021-03-09 14:08:57 -05:00
|
|
|
useIR = true
|
2021-04-17 19:55:00 -04:00
|
|
|
freeCompilerArgs = listOf(
|
|
|
|
"-Xopt-in=kotlin.contracts.ExperimentalContracts",
|
|
|
|
"-Xinline-classes"
|
|
|
|
)
|
2021-03-09 14:08:57 -05:00
|
|
|
}
|
2020-10-08 23:14:43 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
tasks.dokkaHtml {
|
2020-11-17 14:53:02 -05:00
|
|
|
outputDirectory.set(rootDir.resolve("dokka"))
|
2020-10-08 23:14:43 -04:00
|
|
|
}
|