-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.sbt
25 lines (21 loc) · 1.01 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
name := "ScalarTurtle"
version := "1.0"
scalaVersion := "2.11.8"
libraryDependencies += "org.scalactic" %% "scalactic" % "3.0.0"
libraryDependencies += "org.scalatest" %% "scalatest" % "3.0.0" % "test"
// add scala-xml dependency when needed (for Scala 2.11 and newer) in a robust way
// this mechanism supports cross-version publishing
// taken from: http://github.com/scala/scala-module-dependency-sample
libraryDependencies := {
CrossVersion.partialVersion(scalaVersion.value) match {
// if scala 2.11+ is used, add dependency on scala-xml module
case Some((2, scalaMajor)) if scalaMajor >= 11 =>
libraryDependencies.value ++ Seq(
"org.scala-lang.modules" %% "scala-xml" % "1.0.3",
"org.scala-lang.modules" %% "scala-parser-combinators" % "1.0.3",
"org.scala-lang.modules" %% "scala-swing" % "1.0.1")
case _ =>
// or just libraryDependencies.value if you don't depend on scala-swing
libraryDependencies.value :+ "org.scala-lang" % "scala-swing" % scalaVersion.value
}
}