Created
February 4, 2014 18:47
-
-
Save ubourdon/8809798 to your computer and use it in GitHub Desktop.
example cross building sbt config file
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import sbt._ | |
| import sbt.Keys._ | |
| object ScalaTestEmbededMongoBuild extends Build { | |
| lazy val root = Project(id = "simplyscala-server", base = file("."), | |
| settings = Project.defaultSettings ++ Seq( | |
| name := "scalatest-embedmongo", | |
| organization := "com.github.simplyscala", | |
| description := "API to use embeded mongoDb database for testing in Scala", | |
| version := "0.2.2", | |
| scalaVersion := "2.10.1", | |
| crossScalaVersions := Seq("2.9.1", "2.9.2", "2.10"), | |
| libraryDependencies <++= (scalaVersion) { scalaVersion => Seq( | |
| "de.flapdoodle.embed" % "de.flapdoodle.embed.mongo" % "1.41", | |
| "org.scalatest" %% "scalatest" % CrossDependencies.scalatest_version(scalaVersion) % "test", | |
| "com.novus" %% "salat" % CrossDependencies.salat_version(scalaVersion) % "test") | |
| )}, | |
| ) | |
| ) | |
| object CrossDependencies { | |
| def scalatest_version(scala_version: String) = if(scala_version startsWith "2.9") "1.8" else "1.9.1" | |
| def salat_version(scala_version: String) = if(scala_version startsWith "2.9") "1.9.2-SNAPSHOT" else "1.9.5" | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment