Skip to content

Commit 283b0d7

Browse files
committed
add Scala 3 to crossbuild
1 parent 3375e8e commit 283b0d7

File tree

3 files changed

+15
-6
lines changed

3 files changed

+15
-6
lines changed

.travis.yml

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import: scala/scala-dev:travis/default.yml
55
language: scala
66

77
scala:
8+
- 3.0.0-RC1
89
- 2.11.12
910
- 2.12.13
1011
- 2.13.5

build.sbt

+13-6
Original file line numberDiff line numberDiff line change
@@ -73,10 +73,11 @@ lazy val scalaJava8Compat = (project in file("."))
7373

7474
libraryDependencies += "com.novocode" % "junit-interface" % "0.11" % "test",
7575

76-
// we're still in 0.x land so we could choose to break bincompat,
77-
// but let's at least be aware when we're doing it. also we should
78-
// think about going 1.0, it's been a while
79-
scalaModuleMimaPreviousVersion := Some("0.9.1"),
76+
scalaModuleMimaPreviousVersion := {
77+
// pending resolution of https://github.com/scalacenter/sbt-version-policy/issues/62
78+
if (isDotty.value) None
79+
else Some("0.9.1")
80+
},
8081

8182
mimaBinaryIssueFilters ++= {
8283
import com.typesafe.tools.mima.core._, ProblemFilters._
@@ -146,8 +147,14 @@ lazy val scalaJava8Compat = (project in file("."))
146147
},
147148
JavaDoc / javacOptions := Seq("-Xdoclint:none"),
148149
JavaDoc / packageDoc / artifactName := ((sv, mod, art) => "" + mod.name + "_" + sv.binary + "-" + mod.revision + "-javadoc.jar"),
149-
libraryDependencies += compilerPlugin("com.typesafe.genjavadoc" % "genjavadoc-plugin" % "0.16" cross CrossVersion.full),
150-
Compile / scalacOptions += "-P:genjavadoc:out=" + (target.value / "java")
150+
libraryDependencies ++= (
151+
if (isDotty.value) Seq()
152+
else Seq(compilerPlugin("com.typesafe.genjavadoc" % "genjavadoc-plugin" % "0.16" cross CrossVersion.full))
153+
),
154+
Compile / scalacOptions ++= (
155+
if (isDotty.value) Seq()
156+
else Seq(s"""-P:genjavadoc:out=${target.value / "java"}""")
157+
),
151158
)
152159
}
153160
)

project/plugins.sbt

+1
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
addSbtPlugin("org.scala-lang.modules" % "sbt-scala-module" % "2.2.4")
22
addSbtPlugin("ch.epfl.scala" % "sbt-version-policy" % "1.0.0-RC5")
3+
addSbtPlugin("ch.epfl.lamp" % "sbt-dotty" % "0.5.3")

0 commit comments

Comments
 (0)