diff --git a/CHANGELOG.md b/CHANGELOG.md index 7d56250..bc66dad 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,11 @@ Changelog **Unreleased** -------------- +1.4.2 +----- + +_2024-10-22_ + - **Enhancement**: Better handle name shadowing in `SlotReused` lint and reduce false positives. - Test against lint `31.8.0-alpha07`. - Various doc fixes. diff --git a/build.gradle.kts b/build.gradle.kts index 08188ef..d88f990 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -7,6 +7,7 @@ import com.diffplug.gradle.spotless.SpotlessExtension import com.google.devtools.ksp.gradle.KspTask import com.vanniktech.maven.publish.MavenPublishBaseExtension import io.gitlab.arturbosch.detekt.Detekt +import org.jetbrains.dokka.gradle.DokkaExtension import org.jetbrains.dokka.gradle.DokkaTask import org.jetbrains.kotlin.gradle.dsl.JvmTarget import org.jetbrains.kotlin.gradle.tasks.KotlinCompile @@ -15,7 +16,7 @@ plugins { alias(libs.plugins.kotlin.jvm) apply false alias(libs.plugins.spotless) apply false alias(libs.plugins.mavenPublish) apply false - alias(libs.plugins.dokka) apply false + alias(libs.plugins.dokka) alias(libs.plugins.detekt) alias(libs.plugins.lint) apply false alias(libs.plugins.ksp) apply false @@ -108,6 +109,17 @@ allprojects { } } +dokka { + dokkaPublications.html { + outputDirectory.set(rootDir.resolve("docs/api/1.x")) + includes.from(project.layout.projectDirectory.file("docs/index.md")) + } +} + +dependencies { + dokka(project(":compose-lint-checks")) +} + subprojects { pluginManager.withPlugin("java") { configure { @@ -135,8 +147,8 @@ subprojects { pluginManager.withPlugin("com.vanniktech.maven.publish") { apply(plugin = "org.jetbrains.dokka") - tasks.withType().configureEach { - outputDirectory.set(rootDir.resolve("docs/api/0.x")) + configure { + dokkaPublicationDirectory.set(layout.buildDirectory.dir("dokkaDir")) dokkaSourceSets.configureEach { skipDeprecated.set(true) } } diff --git a/deploy_website.sh b/deploy_website.sh index 48a3112..8bd6472 100755 --- a/deploy_website.sh +++ b/deploy_website.sh @@ -23,7 +23,7 @@ if ! [[ ${local} || ${ci} ]]; then # Move working directory into temp folder cd ${DIR} # Generate the API docs - ./gradlew dokkaHtml --no-configuration-cache + ./gradlew :dokkaGenerate fi # Copy in special files that GitHub wants in the project root. diff --git a/gradle.properties b/gradle.properties index 9d60b2e..700aa14 100644 --- a/gradle.properties +++ b/gradle.properties @@ -18,6 +18,10 @@ android.lint.useK2Uast=true # https://github.com/google/ksp/issues/1839 ksp.useKSP2=false +# Dokka flags +org.jetbrains.dokka.experimental.gradle.pluginMode=V2Enabled +org.jetbrains.dokka.experimental.gradle.pluginMode.noWarn=true + # Versioning bits GROUP=com.slack.lint.compose POM_URL=https://github.com/slackhq/compose-lints/ @@ -29,4 +33,4 @@ POM_DEVELOPER_ID=slackhq POM_DEVELOPER_NAME=Salesforce, Inc. POM_DEVELOPER_URL=https://github.com/slackhq POM_INCEPTION_YEAR=2023 -VERSION_NAME=1.5.0-SNAPSHOT +VERSION_NAME=1.4.2 diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index 128a4c5..3703658 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -8,7 +8,7 @@ lint-latest = "31.8.0-alpha07" [plugins] detekt = { id = "io.gitlab.arturbosch.detekt", version = "1.23.7" } -dokka = { id = "org.jetbrains.dokka", version = "1.9.20" } +dokka = { id = "org.jetbrains.dokka", version = "2.0.0-Beta" } lint = { id = "com.android.lint", version = "8.7.1" } kotlin-jvm = { id = "org.jetbrains.kotlin.jvm", version.ref = "kotlin" } ksp = { id = "com.google.devtools.ksp", version = "2.0.21-1.0.25" }