diff --git a/ivy/src/main/scala/sbt/ConflictWarning.scala b/ivy/src/main/scala/sbt/ConflictWarning.scala index 8e0b07f7d..7498a4f13 100644 --- a/ivy/src/main/scala/sbt/ConflictWarning.scala +++ b/ivy/src/main/scala/sbt/ConflictWarning.scala @@ -32,7 +32,7 @@ object ConflictWarning log.log(config.level, conflictMsgs.mkString(msg, "\n ", "")) if(config.failOnConflict) - error("Conflicts in " + conflicts.map(_._1).mkString(", ") ) + sys.error("Conflicts in " + conflicts.map(_._1).mkString(", ") ) } } @@ -51,7 +51,7 @@ object ConflictWarning log.log(config.level, conflictMsgs.mkString(pre, "\n ", "")) if(config.failOnConflict) { val summary = crossMismatches.map{ case ((org,raw),_) => idString(org,raw)}.mkString(", ") - error("Conflicting cross-version suffixes in: " + summary) + sys.error("Conflicting cross-version suffixes in: " + summary) } } } diff --git a/ivy/src/main/scala/sbt/Ivy.scala b/ivy/src/main/scala/sbt/Ivy.scala index fee28808e..68dc273d8 100644 --- a/ivy/src/main/scala/sbt/Ivy.scala +++ b/ivy/src/main/scala/sbt/Ivy.scala @@ -478,10 +478,10 @@ private object IvySbt { def check(found: NodeSeq, expected: String, label: String) = if(found.isEmpty) - error("Missing " + label + " in inline Ivy XML.") + sys.error("Missing " + label + " in inline Ivy XML.") else { val str = found.text - if(str != expected) error("Inconsistent " + label + " in inline Ivy XML. Expected '" + expected + "', got '" + str + "'") + if(str != expected) sys.error("Inconsistent " + label + " in inline Ivy XML. Expected '" + expected + "', got '" + str + "'") } check(info \ "@organisation", module.organization, "organisation") check(info \ "@module", module.name, "name") @@ -637,7 +637,7 @@ private object IvySbt md match { case dmd: DefaultModuleDescriptor => dmd - case _ => error("Unknown ModuleDescriptor type.") + case _ => sys.error("Unknown ModuleDescriptor type.") } def getConfigurations(module: ModuleDescriptor, configurations: Option[Iterable[Configuration]]) = configurations match diff --git a/ivy/src/main/scala/sbt/IvyCache.scala b/ivy/src/main/scala/sbt/IvyCache.scala index 1a22a9977..3ff8432f0 100644 --- a/ivy/src/main/scala/sbt/IvyCache.scala +++ b/ivy/src/main/scala/sbt/IvyCache.scala @@ -102,6 +102,6 @@ private class FileDownloader extends ResourceDownloader with NotNull val part = new File(dest.getAbsolutePath + ".part") FileUtil.copy(resource.openStream, part, null) if(!part.renameTo(dest)) - error("Could not move temporary file " + part + " to final location " + dest) + sys.error("Could not move temporary file " + part + " to final location " + dest) } } \ No newline at end of file diff --git a/ivy/src/main/scala/sbt/MakePom.scala b/ivy/src/main/scala/sbt/MakePom.scala index 2421c68c4..639400db0 100644 --- a/ivy/src/main/scala/sbt/MakePom.scala +++ b/ivy/src/main/scala/sbt/MakePom.scala @@ -275,7 +275,7 @@ class MakePom(val log: Logger) def toID(name: String) = checkID(name.filter(isValidIDCharacter).mkString, name) def isValidIDCharacter(c: Char) = c.isLetterOrDigit - private def checkID(id: String, name: String) = if(id.isEmpty) error("Could not convert '" + name + "' to an ID") else id + private def checkID(id: String, name: String) = if(id.isEmpty) sys.error("Could not convert '" + name + "' to an ID") else id def mavenRepository(repo: MavenRepository): XNode = mavenRepository(toID(repo.name), repo.name, repo.root) def mavenRepository(id: String, name: String, root: String): XNode = diff --git a/ivy/src/main/scala/sbt/ProjectResolver.scala b/ivy/src/main/scala/sbt/ProjectResolver.scala index 4c2d046db..a3b31c298 100644 --- a/ivy/src/main/scala/sbt/ProjectResolver.scala +++ b/ivy/src/main/scala/sbt/ProjectResolver.scala @@ -22,7 +22,7 @@ package sbt class ProjectResolver(name: String, map: Map[ModuleRevisionId, ModuleDescriptor]) extends ResolverAdapter { def getName = name - def setName(name: String) = error("Setting name not supported by ProjectResolver") + def setName(name: String) = sys.error("Setting name not supported by ProjectResolver") override def toString = "ProjectResolver(" + name + ", mapped: " + map.keys.mkString(", ") + ")" def getDependency(dd: DependencyDescriptor, data: ResolveData): ResolvedModuleRevision = @@ -59,7 +59,7 @@ class ProjectResolver(name: String, map: Map[ModuleRevisionId, ModuleDescriptor] } // doesn't support publishing - def publish(artifact: IArtifact, src: File, overwrite: Boolean) = error("Publish not supported by ProjectResolver") + def publish(artifact: IArtifact, src: File, overwrite: Boolean) = sys.error("Publish not supported by ProjectResolver") def beginPublishTransaction(module: ModuleRevisionId, overwrite: Boolean) {} def abortPublishTransaction() {} def commitPublishTransaction() {} @@ -77,5 +77,5 @@ class ProjectResolver(name: String, map: Map[ModuleRevisionId, ModuleDescriptor] def dumpSettings() {} def setSettings(settings: ResolverSettings) { this.settings = Some(settings) } - def getRepositoryCacheManager = settings match { case Some(s) => s.getDefaultRepositoryCacheManager; case None => error("No settings defined for ProjectResolver") } + def getRepositoryCacheManager = settings match { case Some(s) => s.getDefaultRepositoryCacheManager; case None => sys.error("No settings defined for ProjectResolver") } }