aboutsummaryrefslogtreecommitdiff
path: root/runners
diff options
context:
space:
mode:
Diffstat (limited to 'runners')
-rw-r--r--runners/build.gradle.kts9
-rw-r--r--runners/cli/build.gradle.kts5
-rw-r--r--runners/gradle-plugin/api/gradle-plugin.api179
-rw-r--r--runners/gradle-plugin/build.gradle.kts16
-rw-r--r--runners/maven-plugin/build.gradle.kts25
5 files changed, 206 insertions, 28 deletions
diff --git a/runners/build.gradle.kts b/runners/build.gradle.kts
deleted file mode 100644
index 095367ad..00000000
--- a/runners/build.gradle.kts
+++ /dev/null
@@ -1,9 +0,0 @@
-subprojects {
- apply {
- plugin("maven-publish")
- }
-
- tasks.processResources {
- duplicatesStrategy = DuplicatesStrategy.WARN
- }
-}
diff --git a/runners/cli/build.gradle.kts b/runners/cli/build.gradle.kts
index 73b01acb..b522dbdd 100644
--- a/runners/cli/build.gradle.kts
+++ b/runners/cli/build.gradle.kts
@@ -2,6 +2,8 @@ import org.jetbrains.DokkaPublicationBuilder.Component.Shadow
import org.jetbrains.registerDokkaArtifactPublication
plugins {
+ org.jetbrains.conventions.`kotlin-jvm`
+ org.jetbrains.conventions.`maven-publish`
id("com.github.johnrengelman.shadow")
}
@@ -23,8 +25,7 @@ tasks {
}
}
-registerDokkaArtifactPublication("dokkaCli"){
+registerDokkaArtifactPublication("dokkaCli") {
artifactId = "dokka-cli"
component = Shadow
}
-
diff --git a/runners/gradle-plugin/api/gradle-plugin.api b/runners/gradle-plugin/api/gradle-plugin.api
new file mode 100644
index 00000000..fead39f9
--- /dev/null
+++ b/runners/gradle-plugin/api/gradle-plugin.api
@@ -0,0 +1,179 @@
+public abstract class org/jetbrains/dokka/gradle/AbstractDokkaLeafTask : org/jetbrains/dokka/gradle/AbstractDokkaTask {
+ public fun <init> ()V
+ public final fun getDokkaSourceSets ()Lorg/gradle/api/NamedDomainObjectContainer;
+ protected final fun getUnsuppressedSourceSets ()Ljava/util/List;
+}
+
+public abstract class org/jetbrains/dokka/gradle/AbstractDokkaParentTask : org/jetbrains/dokka/gradle/AbstractDokkaTask {
+ public fun <init> ()V
+ public final fun addChildTask (Ljava/lang/String;)V
+ public final fun addChildTask (Lorg/jetbrains/dokka/gradle/AbstractDokkaTask;)V
+ public final fun addChildTasks (Ljava/lang/Iterable;Ljava/lang/String;)V
+ public final fun addSubprojectChildTasks (Ljava/lang/String;)V
+ public final fun removeChildTask (Ljava/lang/String;)V
+ public final fun removeChildTask (Lorg/jetbrains/dokka/gradle/AbstractDokkaTask;)V
+ public final fun removeChildTasks (Ljava/lang/Iterable;)V
+ public final fun removeChildTasks (Ljava/lang/Iterable;Ljava/lang/String;)V
+ public final fun removeChildTasks (Lorg/gradle/api/Project;)V
+ public final fun removeSubprojectChildTasks (Ljava/lang/String;)V
+}
+
+public abstract class org/jetbrains/dokka/gradle/AbstractDokkaTask : org/gradle/api/DefaultTask {
+ public fun <init> ()V
+ public final fun doFirst (Lgroovy/lang/Closure;)Lorg/gradle/api/Task;
+ public final fun doFirst (Lorg/gradle/api/Action;)Lorg/gradle/api/Task;
+ public abstract fun getCacheRoot ()Lorg/gradle/api/file/DirectoryProperty;
+ public final fun getFailOnWarning ()Lorg/gradle/api/provider/Property;
+ public final fun getModuleName ()Lorg/gradle/api/provider/Property;
+ public final fun getModuleVersion ()Lorg/gradle/api/provider/Property;
+ public final fun getOfflineMode ()Lorg/gradle/api/provider/Property;
+ public abstract fun getOutputDirectory ()Lorg/gradle/api/file/DirectoryProperty;
+ public final fun getPlugins ()Lorg/gradle/api/artifacts/Configuration;
+ public final fun getPluginsConfiguration ()Lorg/gradle/api/provider/ListProperty;
+ public final fun getPluginsMapConfiguration ()Lorg/gradle/api/provider/MapProperty;
+ public final fun getRuntime ()Lorg/gradle/api/artifacts/Configuration;
+ public final fun getSuppressInheritedMembers ()Lorg/gradle/api/provider/Property;
+ public final fun getSuppressObviousFunctions ()Lorg/gradle/api/provider/Property;
+}
+
+public final class org/jetbrains/dokka/gradle/DokkaBootstrapFactoryKt {
+ public static final fun DokkaBootstrap (Lorg/gradle/api/artifacts/Configuration;Lkotlin/reflect/KClass;)Lorg/jetbrains/dokka/DokkaBootstrap;
+}
+
+public abstract class org/jetbrains/dokka/gradle/DokkaCollectorTask : org/jetbrains/dokka/gradle/AbstractDokkaParentTask {
+ public fun <init> ()V
+}
+
+public abstract interface class org/jetbrains/dokka/gradle/DokkaMultiModuleFileLayout {
+ public abstract fun targetChildOutputDirectory (Lorg/jetbrains/dokka/gradle/DokkaMultiModuleTask;Lorg/jetbrains/dokka/gradle/AbstractDokkaTask;)Lorg/gradle/api/provider/Provider;
+}
+
+public final class org/jetbrains/dokka/gradle/DokkaMultiModuleFileLayout$CompactInParent : org/jetbrains/dokka/gradle/DokkaMultiModuleFileLayout {
+ public static final field INSTANCE Lorg/jetbrains/dokka/gradle/DokkaMultiModuleFileLayout$CompactInParent;
+ public fun targetChildOutputDirectory (Lorg/jetbrains/dokka/gradle/DokkaMultiModuleTask;Lorg/jetbrains/dokka/gradle/AbstractDokkaTask;)Lorg/gradle/api/provider/Provider;
+}
+
+public final class org/jetbrains/dokka/gradle/DokkaMultiModuleFileLayout$NoCopy : org/jetbrains/dokka/gradle/DokkaMultiModuleFileLayout {
+ public static final field INSTANCE Lorg/jetbrains/dokka/gradle/DokkaMultiModuleFileLayout$NoCopy;
+ public fun targetChildOutputDirectory (Lorg/jetbrains/dokka/gradle/DokkaMultiModuleTask;Lorg/jetbrains/dokka/gradle/AbstractDokkaTask;)Lorg/gradle/api/provider/Provider;
+}
+
+public abstract class org/jetbrains/dokka/gradle/DokkaMultiModuleTask : org/jetbrains/dokka/gradle/AbstractDokkaParentTask {
+ public fun <init> ()V
+ public final fun getFileLayout ()Lorg/gradle/api/provider/Property;
+ public abstract fun getIncludes ()Lorg/gradle/api/file/ConfigurableFileCollection;
+ public fun getTaskDependencies ()Lorg/gradle/api/internal/tasks/TaskDependencyInternal;
+ public synthetic fun getTaskDependencies ()Lorg/gradle/api/tasks/TaskDependency;
+}
+
+public class org/jetbrains/dokka/gradle/DokkaPlugin : org/gradle/api/Plugin {
+ public fun <init> ()V
+ public synthetic fun apply (Ljava/lang/Object;)V
+ public fun apply (Lorg/gradle/api/Project;)V
+}
+
+public abstract class org/jetbrains/dokka/gradle/DokkaTask : org/jetbrains/dokka/gradle/AbstractDokkaLeafTask {
+ public fun <init> ()V
+}
+
+public abstract class org/jetbrains/dokka/gradle/DokkaTaskPartial : org/jetbrains/dokka/gradle/AbstractDokkaLeafTask {
+ public fun <init> ()V
+}
+
+public class org/jetbrains/dokka/gradle/GradleDokkaSourceSetBuilder : org/jetbrains/dokka/DokkaConfigurationBuilder {
+ public fun <init> (Ljava/lang/String;Lorg/gradle/api/Project;Lorg/gradle/api/NamedDomainObjectFactory;)V
+ public final fun DokkaSourceSetID (Ljava/lang/String;)Lorg/jetbrains/dokka/DokkaSourceSetID;
+ public synthetic fun build ()Ljava/lang/Object;
+ public fun build ()Lorg/jetbrains/dokka/DokkaSourceSetImpl;
+ public final fun dependsOn (Ljava/lang/String;)V
+ public final fun dependsOn (Lorg/gradle/api/tasks/SourceSet;)V
+ public final fun dependsOn (Lorg/jetbrains/dokka/DokkaConfiguration$DokkaSourceSet;)V
+ public final fun dependsOn (Lorg/jetbrains/dokka/DokkaSourceSetID;)V
+ public final fun dependsOn (Lorg/jetbrains/dokka/gradle/GradleDokkaSourceSetBuilder;)V
+ public final fun externalDocumentationLink (Lgroovy/lang/Closure;)V
+ public final fun externalDocumentationLink (Ljava/lang/String;Ljava/lang/String;)V
+ public final fun externalDocumentationLink (Ljava/net/URL;Ljava/net/URL;)V
+ public final fun externalDocumentationLink (Lorg/gradle/api/Action;)V
+ public static synthetic fun externalDocumentationLink$default (Lorg/jetbrains/dokka/gradle/GradleDokkaSourceSetBuilder;Ljava/lang/String;Ljava/lang/String;ILjava/lang/Object;)V
+ public static synthetic fun externalDocumentationLink$default (Lorg/jetbrains/dokka/gradle/GradleDokkaSourceSetBuilder;Ljava/net/URL;Ljava/net/URL;ILjava/lang/Object;)V
+ public final fun getApiVersion ()Lorg/gradle/api/provider/Property;
+ public final fun getClasspath ()Lorg/gradle/api/file/ConfigurableFileCollection;
+ public final fun getDependentSourceSets ()Lorg/gradle/api/provider/SetProperty;
+ public final fun getDisplayName ()Lorg/gradle/api/provider/Property;
+ public final fun getDocumentedVisibilities ()Lorg/gradle/api/provider/SetProperty;
+ public final fun getExternalDocumentationLinks ()Lorg/gradle/api/provider/SetProperty;
+ public final fun getIncludeNonPublic ()Lorg/gradle/api/provider/Property;
+ public final fun getIncludes ()Lorg/gradle/api/file/ConfigurableFileCollection;
+ public final fun getJdkVersion ()Lorg/gradle/api/provider/Property;
+ public final fun getLanguageVersion ()Lorg/gradle/api/provider/Property;
+ public final fun getName ()Ljava/lang/String;
+ public final fun getNoAndroidSdkLink ()Lorg/gradle/api/provider/Property;
+ public final fun getNoJdkLink ()Lorg/gradle/api/provider/Property;
+ public final fun getNoStdlibLink ()Lorg/gradle/api/provider/Property;
+ public final fun getPerPackageOptions ()Lorg/gradle/api/provider/ListProperty;
+ public final fun getPlatform ()Lorg/gradle/api/provider/Property;
+ public final fun getReportUndocumented ()Lorg/gradle/api/provider/Property;
+ public final fun getSamples ()Lorg/gradle/api/file/ConfigurableFileCollection;
+ public final fun getSkipDeprecated ()Lorg/gradle/api/provider/Property;
+ public final fun getSkipEmptyPackages ()Lorg/gradle/api/provider/Property;
+ public final fun getSourceLinks ()Lorg/gradle/api/provider/SetProperty;
+ public final fun getSourceRoots ()Lorg/gradle/api/file/ConfigurableFileCollection;
+ public final fun getSourceSetID ()Lorg/jetbrains/dokka/DokkaSourceSetID;
+ public final fun getSuppress ()Lorg/gradle/api/provider/Property;
+ public final fun getSuppressGeneratedFiles ()Lorg/gradle/api/provider/Property;
+ public final fun getSuppressedFiles ()Lorg/gradle/api/file/ConfigurableFileCollection;
+ public final fun perPackageOption (Lgroovy/lang/Closure;)V
+ public final fun perPackageOption (Lorg/gradle/api/Action;)V
+ public final fun sourceLink (Lgroovy/lang/Closure;)V
+ public final fun sourceLink (Lorg/gradle/api/Action;)V
+ public final fun sourceRoot (Ljava/io/File;)V
+ public final fun sourceRoot (Ljava/lang/String;)V
+}
+
+public final class org/jetbrains/dokka/gradle/GradleDokkaSourceSetBuilderExtensionsKt {
+ public static final fun dependsOn (Lorg/jetbrains/dokka/gradle/GradleDokkaSourceSetBuilder;Lcom/android/build/gradle/api/AndroidSourceSet;)V
+ public static final fun dependsOn (Lorg/jetbrains/dokka/gradle/GradleDokkaSourceSetBuilder;Lorg/jetbrains/kotlin/gradle/plugin/KotlinSourceSet;)V
+ public static final fun kotlinSourceSet (Lorg/jetbrains/dokka/gradle/GradleDokkaSourceSetBuilder;Lorg/jetbrains/kotlin/gradle/plugin/KotlinSourceSet;)V
+}
+
+public final class org/jetbrains/dokka/gradle/GradleDokkaSourceSetBuilderFactoryKt {
+ public static final fun gradleDokkaSourceSetBuilderFactory (Lorg/jetbrains/dokka/gradle/AbstractDokkaTask;)Lorg/gradle/api/NamedDomainObjectFactory;
+}
+
+public final class org/jetbrains/dokka/gradle/GradleExternalDocumentationLinkBuilder : org/jetbrains/dokka/DokkaConfigurationBuilder {
+ public fun <init> (Lorg/gradle/api/Project;)V
+ public synthetic fun build ()Ljava/lang/Object;
+ public fun build ()Lorg/jetbrains/dokka/ExternalDocumentationLinkImpl;
+ public final fun getPackageListUrl ()Lorg/gradle/api/provider/Property;
+ public final fun getUrl ()Lorg/gradle/api/provider/Property;
+}
+
+public final class org/jetbrains/dokka/gradle/GradlePackageOptionsBuilder : org/jetbrains/dokka/DokkaConfigurationBuilder {
+ public fun <init> (Lorg/gradle/api/Project;)V
+ public synthetic fun build ()Ljava/lang/Object;
+ public fun build ()Lorg/jetbrains/dokka/PackageOptionsImpl;
+ public final fun getDocumentedVisibilities ()Lorg/gradle/api/provider/SetProperty;
+ public final fun getIncludeNonPublic ()Lorg/gradle/api/provider/Property;
+ public final fun getMatchingRegex ()Lorg/gradle/api/provider/Property;
+ public final fun getReportUndocumented ()Lorg/gradle/api/provider/Property;
+ public final fun getSkipDeprecated ()Lorg/gradle/api/provider/Property;
+ public final fun getSuppress ()Lorg/gradle/api/provider/Property;
+}
+
+public final class org/jetbrains/dokka/gradle/GradleSourceLinkBuilder : org/jetbrains/dokka/DokkaConfigurationBuilder {
+ public fun <init> (Lorg/gradle/api/Project;)V
+ public synthetic fun build ()Ljava/lang/Object;
+ public fun build ()Lorg/jetbrains/dokka/SourceLinkDefinitionImpl;
+ public final fun getLocalDirectory ()Lorg/gradle/api/provider/Property;
+ public final fun getRemoteLineSuffix ()Lorg/gradle/api/provider/Property;
+ public final fun getRemoteUrl ()Lorg/gradle/api/provider/Property;
+}
+
+public final class org/jetbrains/dokka/gradle/SourceSetKotlinGistConfigurationKt {
+ public static final fun configureWithKotlinSourceSet (Lorg/jetbrains/dokka/gradle/GradleDokkaSourceSetBuilder;Lorg/jetbrains/kotlin/gradle/plugin/KotlinSourceSet;)V
+}
+
+public final class org/jetbrains/dokka/gradle/kotlin/KotlinClasspathUtilsKt {
+ public static final fun isHMPPEnabled (Lorg/gradle/api/Project;)Z
+}
+
diff --git a/runners/gradle-plugin/build.gradle.kts b/runners/gradle-plugin/build.gradle.kts
index 6845e7f6..89601c69 100644
--- a/runners/gradle-plugin/build.gradle.kts
+++ b/runners/gradle-plugin/build.gradle.kts
@@ -1,13 +1,10 @@
-import org.gradle.configurationcache.extensions.serviceOf
import org.jetbrains.*
plugins {
`kotlin-dsl`
- id("com.gradle.plugin-publish") version "0.20.0"
-}
-
-repositories {
- google()
+ org.jetbrains.conventions.`maven-publish`
+ org.jetbrains.conventions.`base-java`
+ id("com.gradle.plugin-publish")
}
dependencies {
@@ -22,7 +19,7 @@ dependencies {
testImplementation("com.android.tools.build:gradle:4.0.1")
}
-// Gradle will put its own version of the stdlib in the classpath, do not pull our own we will end up with
+// Gradle will put its own version of the stdlib in the classpath, so not pull our own we will end up with
// warnings like 'Runtime JAR files in the classpath should have the same version'
configurations.api.configure {
excludeGradleCommonDependencies()
@@ -86,7 +83,6 @@ publishing {
register<MavenPublication>("pluginMaven") {
configurePom("Dokka ${project.name}")
artifactId = "dokka-gradle-plugin"
- artifact(tasks["javadocJar"])
}
afterEvaluate {
@@ -110,3 +106,7 @@ afterEvaluate { // Workaround for an interesting design choice https://github.co
configureSonatypePublicationIfNecessary("pluginMaven", "dokkaGradlePluginPluginMarkerMaven")
createDokkaPublishTaskIfNecessary()
}
+
+tasks.processResources {
+ duplicatesStrategy = DuplicatesStrategy.WARN
+}
diff --git a/runners/maven-plugin/build.gradle.kts b/runners/maven-plugin/build.gradle.kts
index d62b82dd..e6aab8eb 100644
--- a/runners/maven-plugin/build.gradle.kts
+++ b/runners/maven-plugin/build.gradle.kts
@@ -2,6 +2,11 @@ import org.jetbrains.CrossPlatformExec
import org.jetbrains.SetupMaven
import org.jetbrains.registerDokkaArtifactPublication
+plugins {
+ org.jetbrains.conventions.`kotlin-jvm`
+ org.jetbrains.conventions.`maven-publish`
+}
+
val setupMaven by tasks.register<SetupMaven>("setupMaven")
dependencies {
@@ -16,15 +21,14 @@ dependencies {
val mavenBuildDir = setupMaven.mavenBuildDir
val mavenBinDir = setupMaven.mavenBinDir
-tasks.named<Delete>("clean") {
+tasks.clean {
delete(mavenBuildDir)
delete(mavenBinDir)
}
-/**
- * Generate pom.xml for Maven Plugin Plugin
- */
val generatePom by tasks.registering(Copy::class) {
+ description = "Generate pom.xml for Maven Plugin Plugin"
+
val dokka_version: String by project
inputs.property("dokka_version", dokka_version)
@@ -49,10 +53,9 @@ val generatePom by tasks.registering(Copy::class) {
}
}
-/**
- * Copy compiled classes to [mavenBuildDir] for Maven Plugin Plugin
- */
val syncClasses by tasks.registering(Sync::class) {
+ description = "Copy compiled classes to the Maven build dir, for Maven Plugin task execution"
+
dependsOn(tasks.compileKotlin, tasks.compileJava)
from("$buildDir/classes/kotlin", "$buildDir/classes/java")
into("${setupMaven.mavenBuildDir}/classes/java")
@@ -66,20 +69,24 @@ val helpMojo by tasks.registering(CrossPlatformExec::class) {
dependsOn(setupMaven, generatePom, syncClasses)
workingDir(setupMaven.mavenBuildDir)
commandLine(setupMaven.mvn, "-e", "-B", "org.apache.maven.plugins:maven-plugin-plugin:helpmojo")
+
+ outputs.dir(layout.buildDirectory.dir("maven"))
}
val pluginDescriptor by tasks.registering(CrossPlatformExec::class) {
dependsOn(setupMaven, generatePom, syncClasses)
workingDir(setupMaven.mavenBuildDir)
commandLine(setupMaven.mvn, "-e", "-B", "org.apache.maven.plugins:maven-plugin-plugin:descriptor")
+
+ outputs.dir(layout.buildDirectory.dir("maven/classes/java/main/META-INF/maven"))
}
val sourceJar by tasks.registering(Jar::class) {
archiveClassifier.set("sources")
- from(sourceSets["main"].allSource)
+ from(java.sourceSets["main"].allSource)
}
-tasks.named<Jar>("jar") {
+tasks.jar {
dependsOn(pluginDescriptor, helpMojo)
metaInf {
from("${setupMaven.mavenBuildDir}/classes/java/main/META-INF")