mirror of https://github.com/sbt/sbt.git
enable -deprecation for Scala 2.10
Enable -deprecation flag to catch old code being use when we migrate things. In this commit I moved error to sys.error.
This commit is contained in:
parent
855dff21be
commit
cf4e882ac9
|
|
@ -27,7 +27,7 @@ object Credentials {
|
||||||
def toDirect(c: Credentials): DirectCredentials = c match {
|
def toDirect(c: Credentials): DirectCredentials = c match {
|
||||||
case dc: DirectCredentials => dc
|
case dc: DirectCredentials => dc
|
||||||
case fc: FileCredentials => loadCredentials(fc.path) match {
|
case fc: FileCredentials => loadCredentials(fc.path) match {
|
||||||
case Left(err) => error(err)
|
case Left(err) => sys.error(err)
|
||||||
case Right(dc) => dc
|
case Right(dc) => dc
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -155,7 +155,7 @@ object EvictionWarning {
|
||||||
val transitiveEvictions: mutable.ListBuffer[EvictionPair] = mutable.ListBuffer()
|
val transitiveEvictions: mutable.ListBuffer[EvictionPair] = mutable.ListBuffer()
|
||||||
def guessCompatible(p: EvictionPair): Boolean =
|
def guessCompatible(p: EvictionPair): Boolean =
|
||||||
p.evicteds forall { r =>
|
p.evicteds forall { r =>
|
||||||
options.guessCompatible(r.module, p.winner map { _.module }, module.moduleSettings.ivyScala)
|
options.guessCompatible((r.module, p.winner map { _.module }, module.moduleSettings.ivyScala))
|
||||||
}
|
}
|
||||||
pairs foreach {
|
pairs foreach {
|
||||||
case p if isScalaArtifact(module, p.organization, p.name) =>
|
case p if isScalaArtifact(module, p.organization, p.name) =>
|
||||||
|
|
|
||||||
|
|
@ -313,7 +313,7 @@ object IvyActions {
|
||||||
private[this] def checkFilesPresent(artifacts: Seq[(IArtifact, File)]) {
|
private[this] def checkFilesPresent(artifacts: Seq[(IArtifact, File)]) {
|
||||||
val missing = artifacts filter { case (a, file) => !file.exists }
|
val missing = artifacts filter { case (a, file) => !file.exists }
|
||||||
if (missing.nonEmpty)
|
if (missing.nonEmpty)
|
||||||
error("Missing files for publishing:\n\t" + missing.map(_._2.getAbsolutePath).mkString("\n\t"))
|
sys.error("Missing files for publishing:\n\t" + missing.map(_._2.getAbsolutePath).mkString("\n\t"))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
final class ResolveException(
|
final class ResolveException(
|
||||||
|
|
|
||||||
|
|
@ -220,7 +220,7 @@ object UpdateReport {
|
||||||
|
|
||||||
private[this] def select0(f: DependencyFilter): Seq[File] =
|
private[this] def select0(f: DependencyFilter): Seq[File] =
|
||||||
for (cReport <- report.configurations; mReport <- cReport.modules; (artifact, file) <- mReport.artifacts if f(cReport.configuration, mReport.module, artifact)) yield {
|
for (cReport <- report.configurations; mReport <- cReport.modules; (artifact, file) <- mReport.artifacts if f(cReport.configuration, mReport.module, artifact)) yield {
|
||||||
if (file == null) error("Null file: conf=" + cReport.configuration + ", module=" + mReport.module + ", art: " + artifact)
|
if (file == null) sys.error("Null file: conf=" + cReport.configuration + ", module=" + mReport.module + ", art: " + artifact)
|
||||||
file
|
file
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue