mirror of https://github.com/sbt/sbt.git
Get parent metadata prior to requiring import dependencies
This commit is contained in:
parent
bb4fcfceb6
commit
83e04a8e45
|
|
@ -785,6 +785,16 @@ final case class Resolution(
|
||||||
project: Project
|
project: Project
|
||||||
): Set[ModuleVersion] = {
|
): Set[ModuleVersion] = {
|
||||||
|
|
||||||
|
val needsParent =
|
||||||
|
project.parent.exists { par =>
|
||||||
|
val parentFound = projectCache.contains(par) || errorCache.contains(par)
|
||||||
|
!parentFound
|
||||||
|
}
|
||||||
|
|
||||||
|
if (needsParent)
|
||||||
|
project.parent.toSet
|
||||||
|
else {
|
||||||
|
|
||||||
val approxProperties0 =
|
val approxProperties0 =
|
||||||
project.parent
|
project.parent
|
||||||
.flatMap(projectCache.get)
|
.flatMap(projectCache.get)
|
||||||
|
|
@ -809,7 +819,8 @@ final case class Resolution(
|
||||||
case ("import", dep) => dep.moduleVersion
|
case ("import", dep) => dep.moduleVersion
|
||||||
}
|
}
|
||||||
|
|
||||||
modules.toSet ++ project.parent
|
modules.toSet
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,2 @@
|
||||||
|
org.kie:kie-api:6.5.0.Final:compile
|
||||||
|
org.slf4j:slf4j-api:1.7.2:compile
|
||||||
|
|
@ -607,6 +607,14 @@ object CentralTests extends TestSuite {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
'parentBeforeImports - {
|
||||||
|
* - resolutionCheck(
|
||||||
|
Module("org.kie", "kie-api"),
|
||||||
|
"6.5.0.Final",
|
||||||
|
extraRepo = Some(MavenRepository("https://repository.jboss.org/nexus/content/repositories/public"))
|
||||||
|
)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue