Support scala 2.13.0-pre-* & 2.13.0-M1

Fixes sbt/sbt#3771
Fixes sbt/zinc#460
This commit is contained in:
Dale Wijnand 2017-11-28 15:32:02 +00:00
parent 282b0f7f51
commit 8c1e062fd1
1 changed files with 8 additions and 7 deletions

View File

@ -40,14 +40,15 @@ private[sbt] object ZincComponentCompiler {
private val CompileConf = Some(Configurations.Compile.name)
private[sbt] def getDefaultBridgeModule(scalaVersion: String): ModuleID = {
def compilerBridgeId(scalaVersion: String) = {
// Defaults to bridge for 2.12 for Scala versions bigger than 2.12.x
scalaVersion match {
case sc if (sc startsWith "2.10.") => "compiler-bridge_2.10"
case sc if (sc startsWith "2.11.") => "compiler-bridge_2.11"
case sc if (sc startsWith "2.12.") => "compiler-bridge_2.12"
case sc if (sc startsWith "2.13.0-M") => "compiler-bridge_2.13.0-M2"
case sc if (sc startsWith "2.13.0-RC") => "compiler-bridge_2.13.0-M2"
case _ => "compiler-bridge_2.13"
case sc if (sc startsWith "2.10.") => "compiler-bridge_2.10"
case sc if (sc startsWith "2.11.") => "compiler-bridge_2.11"
case sc if (sc startsWith "2.12.") => "compiler-bridge_2.12"
case "2.13.0-M1" => "compiler-bridge_2.12"
case sc if (sc startsWith "2.13.0-pre-") => "compiler-bridge_2.13.0-M2"
case sc if (sc startsWith "2.13.0-M") => "compiler-bridge_2.13.0-M2"
case sc if (sc startsWith "2.13.0-RC") => "compiler-bridge_2.13.0-M2"
case _ => "compiler-bridge_2.13"
}
}
import xsbti.ArtifactInfo.SbtOrganization