github-releases-bot/app/build.gradle.kts

74 lines
2.2 KiB
Text
Raw Normal View History

2024-02-12 09:35:31 +01:00
import java.time.Instant
import java.time.ZoneId
import java.time.format.DateTimeFormatter
plugins {
// Apply the org.jetbrains.kotlin.jvm Plugin to add support for Kotlin.
alias(libs.plugins.jvm)
// Apply the application plugin to add support for building a CLI application in Java.
application
2024-07-08 14:22:34 +02:00
id("com.google.cloud.tools.jib") version "3.4.3"
2024-02-12 09:35:31 +01:00
}
repositories {
// Use Maven Central for resolving dependencies.
mavenCentral()
maven {
url = uri("https://s01.oss.sonatype.org/content/repositories/snapshots/")
}
}
jib {
2024-02-13 09:17:34 +01:00
to.image = "github-release-bot"
2024-02-12 09:35:31 +01:00
container.creationTime.set(DateTimeFormatter.ISO_DATE_TIME.format(Instant.now().atZone(ZoneId.of("UTC"))))
val buildDir = layout.buildDirectory.get()
outputPaths.imageId = "$buildDir/github-release-bot.id"
outputPaths.digest = "$buildDir/github-release-bot.digest"
outputPaths.imageJson = "$buildDir/github-release-bot.json"
outputPaths.tar = "$buildDir/github-release-bot.tar"
2024-02-12 09:35:31 +01:00
}
dependencies {
implementation("com.ouattararomuald:syndication:2.1.1") {
exclude("com.squareup.okhttp3:okhttp")
}
implementation("com.squareup.okhttp3:okhttp:5.0.0-alpha.12")
implementation(libs.guava)
implementation("com.google.code.gson:gson:2.10.1")
implementation("social.bigbone:bigbone:2.0.0-SNAPSHOT")
2024-03-11 10:35:50 +01:00
val kotestVersion = "5.8.1"
testImplementation("io.kotest:kotest-runner-junit5:$kotestVersion")
testImplementation("io.kotest:kotest-assertions-core:$kotestVersion")
2024-02-12 09:35:31 +01:00
testImplementation("com.willowtreeapps.assertk:assertk:0.28.0")
testImplementation("io.mockk:mockk:1.13.9")
2024-07-26 10:25:20 +02:00
implementation("ch.qos.logback:logback-core:1.5.6")
implementation("ch.qos.logback:logback-classic:1.5.6")
implementation("org.slf4j:slf4j-api:2.0.13")
2024-02-12 09:35:31 +01:00
}
// Apply a specific Java toolchain to ease working on different environments.
java {
toolchain {
languageVersion.set(JavaLanguageVersion.of(17))
}
}
application {
// Define the main class for the application.
mainClass.set("de.rpr.releases.AppKt")
}
tasks.named<Test>("test") {
// Use JUnit Platform for unit tests.
useJUnitPlatform()
}
2024-02-12 15:14:59 +01:00
tasks.withType<Test>().configureEach {
jvmArgs("--add-opens=java.base/java.util=ALL-UNNAMED")
}