Skip to content

Commit

Permalink
build(gradle): Fix applying the dependency analysis plugin
Browse files Browse the repository at this point in the history
As of version 2 this needs to be applied to the individual projects
instead of the root project. This makes the `projectHealth` task
available again.

Signed-off-by: Sebastian Schuberth <sebastian@doubleopen.org>
  • Loading branch information
sschuberth committed Sep 2, 2024
1 parent 934c6aa commit 90a570d
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 2 deletions.
1 change: 0 additions & 1 deletion build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ import org.jetbrains.gradle.ext.settings

plugins {
// Apply third-party plugins.
alias(libs.plugins.dependencyAnalysis)
alias(libs.plugins.gitSemver)
alias(libs.plugins.ideaExt)
alias(libs.plugins.versions)
Expand Down
1 change: 1 addition & 0 deletions buildSrc/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ dependencies {
implementation(files(libs.javaClass.superclass.protectionDomain.codeSource.location))

implementation(libs.jgit)
implementation(libs.plugin.dependencyAnalysis)
implementation(libs.plugin.detekt)
implementation(libs.plugin.dokkatoo)
implementation(libs.plugin.graalVmNativeImage)
Expand Down
2 changes: 2 additions & 0 deletions buildSrc/src/main/kotlin/ort-kotlin-conventions.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,10 @@ plugins {
id("ort-base-conventions")

// Apply third-party plugins.
id("com.autonomousapps.dependency-analysis")
id("dev.adamko.dokkatoo")
id("io.gitlab.arturbosch.detekt")

kotlin("jvm")
}

Expand Down
2 changes: 1 addition & 1 deletion gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,6 @@ xmlutil = "0.90.1"
xz = "1.10"

[plugins]
dependencyAnalysis = { id = "com.autonomousapps.dependency-analysis", version.ref = "dependencyAnalysisPlugin" }
download = { id = "de.undercouch.download", version.ref = "downloadPlugin" }
gitSemver = { id = "com.github.jmongard.git-semver-plugin", version.ref = "gitSemverPlugin" }
ideaExt = { id = "org.jetbrains.gradle.plugin.idea-ext", version.ref = "ideaExtPlugin" }
Expand All @@ -75,6 +74,7 @@ versions = { id = "com.github.ben-manes.versions", version.ref = "versionsPlugin

[libraries]
# These are Maven coordinates for Gradle plugins, which is necessary to use them in precompiled plugin scripts.
plugin-dependencyAnalysis = { module = "com.autonomousapps:dependency-analysis-gradle-plugin", version.ref = "dependencyAnalysisPlugin" }
plugin-detekt = { module = "io.gitlab.arturbosch.detekt:detekt-gradle-plugin", version.ref = "detektPlugin" }
plugin-detekt-formatting = { module = "io.gitlab.arturbosch.detekt:detekt-formatting", version.ref = "detektPlugin" }
plugin-dokkatoo = { module = "dev.adamko.dokkatoo:dokkatoo-plugin", version.ref = "dokkatooPlugin" }
Expand Down

0 comments on commit 90a570d

Please sign in to comment.