From 31d219eb5210d22ed9798c218848a021d80698d2 Mon Sep 17 00:00:00 2001 From: Cedric Beust Date: Thu, 11 Aug 2016 02:46:26 -0800 Subject: [PATCH] Fix version processor bug. Fixes https://github.com/cbeust/kobalt/issues/297 The problem was that when determining the dependencies of a project from the projects it depends on, the current project was included in that collection. --- .../main/kotlin/com/beust/kobalt/maven/DependencyManager2.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/kobalt-plugin-api/src/main/kotlin/com/beust/kobalt/maven/DependencyManager2.kt b/modules/kobalt-plugin-api/src/main/kotlin/com/beust/kobalt/maven/DependencyManager2.kt index c67ffd9d..2a6980df 100644 --- a/modules/kobalt-plugin-api/src/main/kotlin/com/beust/kobalt/maven/DependencyManager2.kt +++ b/modules/kobalt-plugin-api/src/main/kotlin/com/beust/kobalt/maven/DependencyManager2.kt @@ -168,7 +168,7 @@ class DependencyManager2 @Inject constructor(val aether: KobaltAether) { result.add(FileDependency(classDir)) } } - transitiveProjects.forEach { p -> + transitiveProjects.filter { it.name != project?.name }.forEach { p -> maybeAddClassDir(KFiles.joinDir(p.directory, p.classesDir(context))) maybeAddClassDir(KFiles.makeOutputTestDir(p).path) }