aboutsummaryrefslogtreecommitdiff
path: root/dokka-gradle-plugin/src/main
diff options
context:
space:
mode:
authoringo <ingo.kegel@ej-technologies.com>2016-01-06 16:25:34 +0100
committeringo <ingo.kegel@ej-technologies.com>2016-01-06 16:33:37 +0100
commitfa871ac4602474164374009f56fbc8c3a533b504 (patch)
treeb64ac919183597e13bda0f155c02da003a2f7f57 /dokka-gradle-plugin/src/main
parentddd22fc7652f468f57c5a9dca380743eea53be5d (diff)
downloaddokka-fa871ac4602474164374009f56fbc8c3a533b504.tar.gz
dokka-fa871ac4602474164374009f56fbc8c3a533b504.tar.bz2
dokka-fa871ac4602474164374009f56fbc8c3a533b504.zip
gradle plugin: The "includes" and "samples" properties now accept relative file names and the list-typed properties are now more robust.
Diffstat (limited to 'dokka-gradle-plugin/src/main')
-rw-r--r--dokka-gradle-plugin/src/main/kotlin/main.kt12
1 files changed, 6 insertions, 6 deletions
diff --git a/dokka-gradle-plugin/src/main/kotlin/main.kt b/dokka-gradle-plugin/src/main/kotlin/main.kt
index 28600a6b..c214a08e 100644
--- a/dokka-gradle-plugin/src/main/kotlin/main.kt
+++ b/dokka-gradle-plugin/src/main/kotlin/main.kt
@@ -34,13 +34,13 @@ public open class DokkaTask : DefaultTask() {
var outputFormat: String = "html"
var outputDirectory: String = ""
@Input
- var processConfigurations: ArrayList<String> = arrayListOf("compile")
+ var processConfigurations: List<Any?> = arrayListOf("compile")
@Input
- var includes: ArrayList<String> = arrayListOf()
+ var includes: List<Any?> = arrayListOf()
@Input
var linkMappings: ArrayList<LinkMapping> = arrayListOf()
@Input
- var samples: ArrayList<String> = arrayListOf()
+ var samples: List<Any?> = arrayListOf()
fun linkMapping(closure: Closure<Any?>) {
val mapping = LinkMapping()
@@ -65,7 +65,7 @@ public open class DokkaTask : DefaultTask() {
val classpath =
processConfigurations
- .map { allConfigurations?.getByName(it) ?: throw IllegalArgumentException("No configuration $it found") }
+ .map { allConfigurations?.getByName(it.toString()) ?: throw IllegalArgumentException("No configuration $it found") }
.flatMap { it }
if (sourceDirectories.isEmpty()) {
@@ -77,8 +77,8 @@ public open class DokkaTask : DefaultTask() {
DokkaGradleLogger(logger),
classpath.map { it.absolutePath },
sourceDirectories.map { it.absolutePath },
- samples,
- includes,
+ samples.filterNotNull().map { project.file(it).absolutePath },
+ includes.filterNotNull().map { project.file(it).absolutePath },
moduleName,
outputDirectory,
outputFormat,