-
Notifications
You must be signed in to change notification settings - Fork 131
/
Copy pathbuild.sbt
60 lines (53 loc) · 2.03 KB
/
build.sbt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
import ScalaModulePlugin._
scalaVersionsByJvm in ThisBuild := {
val v211 = "2.11.12"
val v212 = "2.12.4"
val v213 = "2.13.0-M2"
Map(
6 -> List(v211 -> true),
7 -> List(v211 -> false),
8 -> List(v212 -> true, v213 -> true, v211 -> false),
9 -> List(v212 -> false, v213 -> false, v211 -> false),
10 -> List(v212 -> false, v213 -> false, v211 -> false),
11 -> List(v212 -> false, v213 -> false, v211 -> false),
12 -> List(v212 -> false, v213 -> false, v211 -> false),
13 -> List(v212 -> false, v213 -> false, v211 -> false),
14 -> List(v212 -> false, v213 -> false, v211 -> false)
)
}
lazy val root = project.in(file("."))
.aggregate(`scala-parser-combinatorsJS`, `scala-parser-combinatorsJVM`)
.settings(disablePublishing)
lazy val `scala-parser-combinators` = crossProject.in(file(".")).
settings(scalaModuleSettings: _*).
jvmSettings(scalaModuleSettingsJVM).
settings(
name := "scala-parser-combinators",
version := "1.0.8-SNAPSHOT",
mimaPreviousVersion := Some("1.0.5"),
apiMappings += (scalaInstance.value.libraryJar ->
url(s"https://www.scala-lang.org/api/${scalaVersion.value}/")),
scalacOptions in (Compile, doc) ++= Seq(
"-diagrams",
"-doc-source-url",
s"https://github.com/scala/scala-parser-combinators/tree/v${version.value}€{FILE_PATH}.scala",
"-sourcepath",
(baseDirectory in LocalRootProject).value.absolutePath,
"-doc-title",
"Scala Parser Combinators",
"-doc-version",
version.value
)
).
jvmSettings(
OsgiKeys.exportPackage := Seq(s"scala.util.parsing.*;version=${version.value}"),
libraryDependencies += "junit" % "junit" % "4.12" % "test",
libraryDependencies += "com.novocode" % "junit-interface" % "0.11" % "test"
).
jsSettings(
// Scala.js cannot run forked tests
fork in Test := false
).
jsConfigure(_.enablePlugins(ScalaJSJUnitPlugin))
lazy val `scala-parser-combinatorsJVM` = `scala-parser-combinators`.jvm
lazy val `scala-parser-combinatorsJS` = `scala-parser-combinators`.js