Skip to content

Cross publish to scala 3.0.0-M3 #402

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ scala:
- 2.12.12
- 2.13.3
- 3.0.0-M2
- 3.0.0-M3

env:
- SCALAJS_VERSION= ADOPTOPENJDK=8
Expand Down
18 changes: 12 additions & 6 deletions build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,10 @@ lazy val root = project
compat212JS,
compat213JVM,
compat213JS,
compat30JVM,
compat30JS,
compat30M2JVM,
compat30M2JS,
compat30M3JVM,
compat30M3JS,
`scalafix-data211`,
`scalafix-data212`,
`scalafix-data213`,
Expand All @@ -53,7 +55,8 @@ lazy val junit = libraryDependencies += "com.novocode" % "junit-interface" % "0.
lazy val scala211 = "2.11.12"
lazy val scala212 = "2.12.12"
lazy val scala213 = "2.13.3"
lazy val scala30 = "3.0.0-M2"
lazy val scala30M2 = "3.0.0-M2"
lazy val scala30M3 = "3.0.0-M3"

lazy val compat = MultiScalaCrossProject(JSPlatform, JVMPlatform, NativePlatform)(
"compat",
Expand Down Expand Up @@ -106,7 +109,8 @@ lazy val compat = MultiScalaCrossProject(JSPlatform, JVMPlatform, NativePlatform
val compat211 = compat(scala211)
val compat212 = compat(scala212)
val compat213 = compat(scala213)
val compat30 = compat(scala30)
val compat30M2 = compat(scala30M2)
val compat30M3 = compat(scala30M3)

lazy val compat211JVM = compat211.jvm
lazy val compat211JS = compat211.js
Expand All @@ -115,8 +119,10 @@ lazy val compat212JVM = compat212.jvm
lazy val compat212JS = compat212.js
lazy val compat213JVM = compat213.jvm
lazy val compat213JS = compat213.js
lazy val compat30JVM = compat30.jvm
lazy val compat30JS = compat30.js
lazy val compat30M2JVM = compat30M2.jvm
lazy val compat30M2JS = compat30M2.js
lazy val compat30M3JVM = compat30M3.jvm
lazy val compat30M3JS = compat30M3.js

lazy val `binary-compat-old` = project
.in(file("binary-compat/old"))
Expand Down
9 changes: 7 additions & 2 deletions project/MultiScalaProject.scala
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,13 @@ import java.io.File
*/
trait MultiScala {
def majorMinor(in: String): String = {
val Array(major, minor, _) = in.split("\\.")
major + minor
val milestoneRegex = raw"\d*-(M\d*)".r
val Array(major, minor, milestone) = in.split("\\.")
val mExt = milestone match {
case milestoneRegex(m) => m
case _ => ""
}
major + minor + mExt
}

def projectIdPerScala(name: String, scalaV: String): String = s"$name${majorMinor(scalaV)}"
Expand Down
2 changes: 1 addition & 1 deletion project/plugins.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ val scalaJSVersion =
val scalaNativeVersion =
Option(System.getenv("SCALANATIVE_VERSION")).filter(_.nonEmpty).getOrElse("0.3.9")

addSbtPlugin("ch.epfl.lamp" % "sbt-dotty" % "0.5.0")
addSbtPlugin("ch.epfl.lamp" % "sbt-dotty" % "0.5.1")
addSbtPlugin("org.scala-js" % "sbt-scalajs" % scalaJSVersion)
addSbtPlugin("org.portable-scala" % "sbt-scalajs-crossproject" % crossVer)
addSbtPlugin("org.scala-native" % "sbt-scala-native" % scalaNativeVersion)
Expand Down