mirror of https://github.com/sbt/sbt.git
Minor cleanups per review
This commit is contained in:
parent
7b22e78fd9
commit
a98c5f4c65
|
|
@ -5,6 +5,9 @@ package sbt.librarymanagement
|
|||
|
||||
import sbt.internal.librarymanagement.StringUtilities.nonEmpty
|
||||
|
||||
/**
|
||||
* DependencyBuilders implements the implicits for % and %% DSL.
|
||||
*/
|
||||
abstract class DependencyBuilders {
|
||||
import DependencyBuilders._
|
||||
|
||||
|
|
@ -31,7 +34,7 @@ object DependencyBuilders {
|
|||
organizationArtifact(name, CrossVersion.binary)
|
||||
|
||||
private def organizationArtifact(name: String, cross: CrossVersion) = {
|
||||
nonEmpty(name, "Artifact ID")
|
||||
nonEmpty(name, "Name")
|
||||
new OrganizationArtifactName(organization, name, cross)
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -6,7 +6,6 @@ package sbt.librarymanagement
|
|||
import java.io.{ IOException, File }
|
||||
import java.net.URL
|
||||
import scala.xml.XML
|
||||
// import org.apache.ivy.plugins.resolver.DependencyResolver
|
||||
import org.xml.sax.SAXParseException
|
||||
|
||||
final class RawRepository(val resolver: AnyRef, name: String) extends Resolver(name) {
|
||||
|
|
|
|||
|
|
@ -270,10 +270,10 @@ object IvyActions {
|
|||
|
||||
implicit def toIvyFilter(f: ArtifactTypeFilter): IvyFilter = new IvyFilter {
|
||||
override def accept(o: Object): Boolean = Option(o) exists {
|
||||
case a: IArtifact => applyFilter(f, a)
|
||||
case a: IArtifact => applyFilter(a)
|
||||
}
|
||||
|
||||
def applyFilter(f: ArtifactTypeFilter, a: IArtifact): Boolean =
|
||||
def applyFilter(a: IArtifact): Boolean =
|
||||
(f.types contains a.getType) ^ f.inverted
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -209,7 +209,7 @@ private[sbt] class CachedResolutionResolveCache {
|
|||
else None) match {
|
||||
case Some(path) =>
|
||||
log.debug(s"parsing ${path.getAbsolutePath.toString}")
|
||||
val ur = JsonUtil.parseUpdateReport( /* md, */ path, cachedDescriptor, log)
|
||||
val ur = JsonUtil.parseUpdateReport(path, cachedDescriptor, log)
|
||||
if (ur.allFiles forall { _.exists }) {
|
||||
updateReportCache(md.getModuleRevisionId) = Right(ur)
|
||||
Some(Right(ur))
|
||||
|
|
|
|||
Loading…
Reference in New Issue