2024-12-19 03:32:35 +00:00
|
|
|
plugins {
|
|
|
|
alias(libs.plugins.kotlin.jvm)
|
2024-12-19 06:50:40 +00:00
|
|
|
alias(libs.plugins.spring.boot)
|
|
|
|
alias(libs.plugins.kotlin.spring)
|
2024-12-19 09:19:35 +00:00
|
|
|
alias(libs.plugins.detekt)
|
2024-12-19 03:32:35 +00:00
|
|
|
}
|
|
|
|
|
2024-12-19 06:50:40 +00:00
|
|
|
apply {
|
|
|
|
plugin("io.spring.dependency-management")
|
|
|
|
}
|
|
|
|
|
|
|
|
|
2024-12-19 09:19:35 +00:00
|
|
|
|
2024-12-19 03:32:35 +00:00
|
|
|
|
2024-12-19 06:50:40 +00:00
|
|
|
allprojects {
|
2024-12-19 09:19:35 +00:00
|
|
|
|
|
|
|
group = "dev.usbharu.hideout"
|
|
|
|
version = "1.0.0-SNAPSHOT"
|
|
|
|
|
2024-12-19 06:50:40 +00:00
|
|
|
repositories {
|
|
|
|
mavenCentral()
|
|
|
|
maven {
|
|
|
|
url = uri("https://git.usbharu.dev/api/packages/usbharu/maven")
|
|
|
|
}
|
|
|
|
maven {
|
|
|
|
name = "GitHubPackages"
|
|
|
|
url = uri("https://maven.pkg.github.com/usbharu/http-signature")
|
|
|
|
credentials {
|
|
|
|
|
|
|
|
username = project.findProperty("gpr.user") as String? ?: System.getenv("USERNAME")
|
|
|
|
password = project.findProperty("gpr.key") as String? ?: System.getenv("TOKEN")
|
|
|
|
}
|
|
|
|
}
|
|
|
|
maven {
|
|
|
|
name = "GitHubPackages2"
|
|
|
|
url = uri("https://maven.pkg.github.com/multim-dev/emoji-kt")
|
|
|
|
credentials {
|
|
|
|
|
|
|
|
username = project.findProperty("gpr.user") as String? ?: System.getenv("USERNAME")
|
|
|
|
password = project.findProperty("gpr.key") as String? ?: System.getenv("TOKEN")
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2024-12-19 09:19:35 +00:00
|
|
|
subprojects {
|
|
|
|
apply {
|
|
|
|
plugin(rootProject.libs.plugins.kotlin.jvm.get().pluginId)
|
|
|
|
plugin(rootProject.libs.plugins.detekt.get().pluginId)
|
|
|
|
}
|
|
|
|
|
|
|
|
dependencies {
|
|
|
|
testImplementation(kotlin("test"))
|
|
|
|
detektPlugins(rootProject.libs.detekt.formatting)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2024-12-19 06:50:40 +00:00
|
|
|
tasks {
|
|
|
|
register("run") {
|
|
|
|
dependsOn(gradle.includedBuild("hideout-core").task(":run"))
|
|
|
|
}
|
2024-12-19 09:19:35 +00:00
|
|
|
withType<io.gitlab.arturbosch.detekt.Detekt> {
|
|
|
|
exclude("**/generated/**")
|
|
|
|
setSource("src/main/kotlin")
|
|
|
|
exclude("build/")
|
|
|
|
configureEach {
|
|
|
|
exclude("**/org/koin/ksp/generated/**", "**/generated/**")
|
|
|
|
}
|
|
|
|
}
|
|
|
|
withType<io.gitlab.arturbosch.detekt.DetektCreateBaselineTask>() {
|
|
|
|
configureEach {
|
|
|
|
exclude("**/org/koin/ksp/generated/**", "**/generated/**")
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
kotlin {
|
|
|
|
jvmToolchain(21)
|
|
|
|
}
|
2024-12-19 03:32:35 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
dependencies {
|
2024-12-19 06:50:40 +00:00
|
|
|
implementation(project(":hideout-core"))
|
|
|
|
implementation(project(":hideout-mastodon"))
|
|
|
|
implementation(project(":hideout-activitypub"))
|
2024-12-19 03:32:35 +00:00
|
|
|
}
|
|
|
|
|
2024-12-19 06:50:40 +00:00
|
|
|
springBoot {
|
|
|
|
buildInfo { }
|
|
|
|
|
|
|
|
mainClass = "dev.usbharu.hideout.SpringApplicationKt"
|
2024-12-19 09:19:35 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
configurations {
|
|
|
|
matching { it.name == "detekt" }.all {
|
|
|
|
resolutionStrategy.eachDependency {
|
|
|
|
if (requested.group == "org.jetbrains.kotlin") {
|
|
|
|
useVersion(io.gitlab.arturbosch.detekt.getSupportedKotlinVersion())
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
detekt {
|
|
|
|
parallel = true
|
|
|
|
config.setFrom(files("../detekt.yml"))
|
|
|
|
buildUponDefaultConfig = true
|
|
|
|
basePath = "${rootDir.absolutePath}/src/main/kotlin"
|
|
|
|
autoCorrect = true
|
2024-12-19 03:32:35 +00:00
|
|
|
}
|