From 6c132165d630d8a034ee1c35c278bf4a4afb93ad Mon Sep 17 00:00:00 2001 From: Mark Harrah Date: Sun, 10 Jan 2010 16:47:38 -0500 Subject: [PATCH] Fixes for Ivy interface component --- ivy/Ivy.scala | 3 ++- ivy/IvyInterface.scala | 6 +++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/ivy/Ivy.scala b/ivy/Ivy.scala index 6b7b89dce..485a6fcf4 100644 --- a/ivy/Ivy.scala +++ b/ivy/Ivy.scala @@ -192,6 +192,7 @@ private object IvySbt manager.setChangingMatcher(PatternMatcher.REGEXP); manager.setChangingPattern(".*-SNAPSHOT"); settings.setDefaultRepositoryCacheManager(manager) + dir.foreach(dir => settings.setDefaultResolutionCacheBasedir(dir.getAbsolutePath)) } def toIvyConfiguration(configuration: Configuration) = { @@ -224,7 +225,7 @@ private object IvySbt private def extra(artifact: Artifact) = { val ea = artifact.classifier match { case Some(c) => artifact.extra("e:classifier" -> c); case None => artifact } - javaMap(artifact.extraAttributes) + javaMap(ea.extraAttributes) } private def javaMap(map: Map[String,String]) = if(map.isEmpty) null diff --git a/ivy/IvyInterface.scala b/ivy/IvyInterface.scala index cd6f7009b..15504e9b8 100644 --- a/ivy/IvyInterface.scala +++ b/ivy/IvyInterface.scala @@ -257,7 +257,7 @@ object Resolver def defaultFileConfiguration = FileConfiguration(true, None) def mavenStylePatterns = Patterns(Nil, mavenStyleBasePattern :: Nil, true) - def ivyStylePatterns = Patterns(Nil, Nil, false) + def ivyStylePatterns = defaultIvyPatterns//Patterns(Nil, Nil, false) def defaultPatterns = mavenStylePatterns def mavenStyleBasePattern = "[organisation]/[module]/[revision]/[artifact]-[revision](-[classifier]).[ext]" @@ -354,7 +354,7 @@ object ModuleConfiguration def apply(org: String, resolver: Resolver): ModuleConfiguration = apply(org, "*", "*", resolver) def apply(org: String, name: String, resolver: Resolver): ModuleConfiguration = ModuleConfiguration(org, name, "*", resolver) } -/* + object Credentials { /** Add the provided credentials to Ivy's credentials cache.*/ @@ -390,4 +390,4 @@ object Credentials private[this] val HostKeys = List("host", "hostname") private[this] val UserKeys = List("user", "user.name", "username") private[this] val PasswordKeys = List("password", "pwd", "pass", "passwd") -}*/ \ No newline at end of file +} \ No newline at end of file