mirror of https://github.com/sbt/sbt.git
Create default artifact for deps from POM files
Dependency descriptors that are created from POM files do not specify their artifacts. In those cases, it is correct to create a default artifact.
This commit is contained in:
parent
fed478cc6b
commit
1e96936c08
|
|
@ -97,7 +97,10 @@ private final class MergedDescriptors(a: DependencyDescriptor, b: DependencyDesc
|
|||
{
|
||||
val dd = new DefaultDependencyArtifactDescriptor(a, a.getDependencyRevisionId.getName, "jar", "jar", null, null)
|
||||
addConfigurations(dd, a.getModuleConfigurations)
|
||||
a.getAllDependencyArtifacts.filter(_ == dd)
|
||||
// If the dependency descriptor is empty, then it means that it has been created from a POM file. In this case,
|
||||
// it is correct to create a seemingly non-existent dependency artifact.
|
||||
if (a.getAllDependencyArtifacts.isEmpty) Array(dd)
|
||||
else a.getAllDependencyArtifacts filter (_ == dd)
|
||||
}
|
||||
private[this] def copyWithConfigurations(dd: DependencyArtifactDescriptor, confs: Seq[String]): DependencyArtifactDescriptor =
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in New Issue