Convert build scripts to Kotlin

Also added some new tasks to only build/install to maven local certain platforms
`buildMinecraft`, `installMinecraft`, `buildDiscord`, `installDiscord`, `buildIRC`, `installIRC`
This commit is contained in:
jmp 2020-12-31 21:26:53 -08:00 committed by Alexander Söderberg
parent d812ea633a
commit 2c188eb130
48 changed files with 519 additions and 499 deletions

View file

@ -1,43 +0,0 @@
import org.jetbrains.dokka.gradle.DokkaTask
plugins {
id 'org.jetbrains.kotlin.jvm' version '1.4.21-2'
id 'org.jetbrains.dokka' version '1.4.20'
}
kotlin {
explicitApi()
}
compileKotlin {
kotlinOptions {
jvmTarget = "1.8"
}
}
compileTestKotlin {
kotlinOptions {
jvmTarget = "1.8"
}
}
dependencies {
api project(':cloud-core')
testImplementation "org.jetbrains.kotlin:kotlin-test-junit5"
}
javadocJar {
from dokkaHtml
}
tasks.withType(DokkaTask).configureEach {
dokkaSourceSets {
main {
includes.from(layout.projectDirectory.file("src/main/descriptions.md").toString())
externalDocumentationLink {
url.set(new URL("https://javadoc.commandframework.cloud/")) //todo fix KDoc linking to JavaDoc
packageListUrl.set(new URL("https://javadoc.commandframework.cloud/allpackages-index.html"))
}
}
}
}

View file

@ -0,0 +1,37 @@
import org.jetbrains.dokka.gradle.DokkaTask
import java.net.URL
plugins {
kotlin("jvm") version "1.4.21-2"
id("org.jetbrains.dokka") version "1.4.20"
}
tasks {
withType<DokkaTask>().configureEach {
dokkaSourceSets.getByName("main") {
includes.from(layout.projectDirectory.file("src/main/descriptions.md").toString())
externalDocumentationLink {
url.set(URL("https://javadoc.commandframework.cloud/")) //todo fix KDoc linking to JavaDoc
packageListUrl.set(URL("https://javadoc.commandframework.cloud/allpackages-index.html"))
}
}
}
javadocJar {
from(dokkaHtml)
}
compileKotlin {
kotlinOptions.jvmTarget = "1.8"
}
compileTestKotlin {
kotlinOptions.jvmTarget = "1.8"
}
}
kotlin {
explicitApi()
}
dependencies {
api(project(":cloud-core"))
testImplementation("org.jetbrains.kotlin", "kotlin-test-junit5")
}