From fa871ac4602474164374009f56fbc8c3a533b504 Mon Sep 17 00:00:00 2001 From: ingo Date: Wed, 6 Jan 2016 16:25:34 +0100 Subject: gradle plugin: The "includes" and "samples" properties now accept relative file names and the list-typed properties are now more robust. --- dokka-gradle-plugin/src/main/kotlin/main.kt | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'dokka-gradle-plugin/src') 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 = arrayListOf("compile") + var processConfigurations: List = arrayListOf("compile") @Input - var includes: ArrayList = arrayListOf() + var includes: List = arrayListOf() @Input var linkMappings: ArrayList = arrayListOf() @Input - var samples: ArrayList = arrayListOf() + var samples: List = arrayListOf() fun linkMapping(closure: Closure) { 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, -- cgit From fc0f3f7574198851be009dd62c720b8372344c95 Mon Sep 17 00:00:00 2001 From: ingo Date: Wed, 6 Jan 2016 18:22:49 +0100 Subject: gradle plugin: up-to-date status did not consider include and sample files --- dokka-gradle-plugin/src/main/kotlin/main.kt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'dokka-gradle-plugin/src') diff --git a/dokka-gradle-plugin/src/main/kotlin/main.kt b/dokka-gradle-plugin/src/main/kotlin/main.kt index c214a08e..ecdeac78 100644 --- a/dokka-gradle-plugin/src/main/kotlin/main.kt +++ b/dokka-gradle-plugin/src/main/kotlin/main.kt @@ -95,7 +95,9 @@ public open class DokkaTask : DefaultTask() { @InputFiles @SkipWhenEmpty - fun getIncludedFiles() : FileCollection = project.files(getSourceDirectories().map { project.fileTree(it) }) + fun getInputFiles() : FileCollection = project.files(getSourceDirectories().map { project.fileTree(it) }) + + project.files(includes) + + project.files(samples) @OutputDirectory fun getOutputDirectoryAsFile() : File = project.file(outputDirectory) -- cgit