-
Notifications
You must be signed in to change notification settings - Fork 5.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
docs build: allow to specify custom dokka repository
- centralize repository management in settings.gradle.kts - allow to specify dokka repository with a gradle property - automatically add mavenLocal for -local dokka versions - specify kotlin version for building plugins in one place
- Loading branch information
Showing
7 changed files
with
50 additions
and
60 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
plugins { | ||
id("org.jetbrains.kotlin.jvm") version "1.8.0" apply false | ||
} |
16 changes: 4 additions & 12 deletions
16
libraries/tools/kotlin-stdlib-docs/plugins/dokka-samples-transformer-plugin/build.gradle
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,17 @@ | ||
plugins { | ||
id 'org.jetbrains.kotlin.jvm' version '1.8.0' | ||
id 'org.jetbrains.kotlin.jvm' | ||
} | ||
description "Dokka Plugin to transform the samples from stdlib" | ||
|
||
repositories { | ||
mavenCentral() | ||
maven { | ||
url 'https://maven.pkg.jetbrains.space/kotlin/p/dokka/dev' | ||
} | ||
mavenLocal() | ||
} | ||
|
||
final String dokka_version = findProperty("dokka_version") | ||
final String dokka_version = property("dokka_version") | ||
|
||
dependencies { | ||
implementation "org.jetbrains.dokka:dokka-base:$dokka_version" | ||
compileOnly "org.jetbrains.dokka:dokka-core:$dokka_version" | ||
compileOnly "org.jetbrains.dokka:dokka-analysis:$dokka_version" | ||
} | ||
|
||
tasks.withType(org.jetbrains.kotlin.gradle.tasks.KotlinCompile) { | ||
kotlinOptions.jvmTarget = "1.8" | ||
kotlin { | ||
jvmToolchain(8) | ||
} | ||
|
16 changes: 4 additions & 12 deletions
16
libraries/tools/kotlin-stdlib-docs/plugins/dokka-stdlib-configuration-plugin/build.gradle
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,17 @@ | ||
plugins { | ||
id 'org.jetbrains.kotlin.jvm' version '1.8.0' | ||
id 'org.jetbrains.kotlin.jvm' | ||
} | ||
description "Dokka Plugin to configure Dokka for stdlib" | ||
|
||
repositories { | ||
mavenCentral() | ||
maven { | ||
url 'https://maven.pkg.jetbrains.space/kotlin/p/dokka/dev' | ||
} | ||
mavenLocal() | ||
} | ||
|
||
final String dokka_version = findProperty("dokka_version") | ||
final String dokka_version = property("dokka_version") | ||
|
||
dependencies { | ||
implementation "org.jetbrains.dokka:dokka-base:$dokka_version" | ||
compileOnly "org.jetbrains.dokka:dokka-core:$dokka_version" | ||
compileOnly "org.jetbrains.dokka:dokka-analysis:$dokka_version" | ||
} | ||
|
||
tasks.withType(org.jetbrains.kotlin.gradle.tasks.KotlinCompile) { | ||
kotlinOptions.jvmTarget = "1.8" | ||
kotlin { | ||
jvmToolchain(8) | ||
} | ||
|
16 changes: 4 additions & 12 deletions
16
libraries/tools/kotlin-stdlib-docs/plugins/dokka-version-filter-plugin/build.gradle
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
pluginManagement { | ||
val dokkaVersion = providers.gradleProperty("dokka_version").get() | ||
val dokkaRepository = providers.gradleProperty("dokka_repository").getOrElse("https://maven.pkg.jetbrains.space/kotlin/p/dokka/dev") | ||
plugins { | ||
id("org.jetbrains.dokka") version(dokkaVersion) | ||
} | ||
|
||
repositories { | ||
gradlePluginPortal() | ||
maven(url = dokkaRepository) | ||
if ("-local" in dokkaVersion) { | ||
mavenLocal() | ||
} | ||
} | ||
} | ||
dependencyResolutionManagement { | ||
repositoriesMode.set(RepositoriesMode.PREFER_PROJECT) | ||
val dokkaVersion = providers.gradleProperty("dokka_version").get() | ||
val dokkaRepository = providers.gradleProperty("dokka_repository").getOrElse("https://maven.pkg.jetbrains.space/kotlin/p/dokka/dev") | ||
repositories { | ||
mavenCentral() | ||
maven(url = dokkaRepository) | ||
if ("-local" in dokkaVersion) { | ||
mavenLocal() | ||
} | ||
} | ||
} | ||
|
||
rootProject.name = "kotlin-stdlib-docs" | ||
|
||
include("kotlin_big") | ||
include("plugins") | ||
include("plugins:dokka-samples-transformer-plugin") | ||
include("plugins:dokka-stdlib-configuration-plugin") | ||
include("plugins:dokka-version-filter-plugin") |