mirror of
https://github.com/InsanusMokrassar/krontab.git
synced 2024-11-16 13:23:53 +00:00
55 lines
1.6 KiB
Groovy
55 lines
1.6 KiB
Groovy
dokkaHtml {
|
|
String dokkaOutputDirectoryPath = null
|
|
switch (true) {
|
|
case project.hasProperty("DOKKA_PATH"):
|
|
dokkaOutputDirectoryPath = project.property("DOKKA_PATH").toString()
|
|
break
|
|
case System.getenv("DOKKA_PATH") != null:
|
|
dokkaOutputDirectoryPath = System.getenv("DOKKA_PATH")
|
|
break
|
|
}
|
|
if (dokkaOutputDirectoryPath != null) {
|
|
File outputDirectoryFile = new File(dokkaOutputDirectoryPath)
|
|
outputDirectoryFile.mkdirs()
|
|
outputDirectory = outputDirectoryFile
|
|
}
|
|
|
|
moduleName.set("kdocs")
|
|
|
|
dokkaSourceSets {
|
|
switch (true) {
|
|
case project.hasProperty("DOKKA_PATH"):
|
|
outputDirectory = new File(project.property("DOKKA_PATH").toString())
|
|
break
|
|
case System.getenv("DOKKA_PATH") != null:
|
|
outputDirectory = new File(System.getenv("DOKKA_PATH"))
|
|
break
|
|
}
|
|
|
|
dokkaSourceSets {
|
|
configureEach {
|
|
skipDeprecated.set(true)
|
|
|
|
sourceLink {
|
|
localDirectory.set(file("./"))
|
|
remoteUrl.set(new URL("https://github.com/InsanusMokrassar/krontab/blob/master/"))
|
|
remoteLineSuffix.set("#L")
|
|
}
|
|
}
|
|
|
|
named("commonMain") {
|
|
sourceRoots.setFrom(findSourcesWithName("commonMain"))
|
|
}
|
|
|
|
//
|
|
// named("jsMain") {
|
|
// sourceRoot { path = "src/jsMain" }
|
|
// }
|
|
//
|
|
// named("jvmMain") {
|
|
// sourceRoot { path = "src/jvmMain" }
|
|
// }
|
|
}
|
|
}
|
|
}
|