I have a root build.sbt
file that looks like this:
organization := "com.acme.foo"
name := "foo-parent"
version := "1.0-SNAPSHOT"
scalaVersion := "2.11.2"
scalacOptions := Seq("-unchecked", "-deprecation", "-encoding", "utf8")
resolvers ++= Seq(
"spray repo" at "http://repo.spray.io/"
)
lazy val root = project.dependsOn(rest,backend)
lazy val rest = project
lazy val backend = project.dependsOn(rest).settings(mainClass in (Compile, run) := Some("com.acme.foo.Main"), fork in run := true)
run in Compile <<= (run in Compile in backend)
In both the backend
and rest
modules the scalaVersion
is also set to 2.11.2, however I keep getting this error when I try to compile from the root:
[warn] ::::::::::::::::::::::::::::::::::::::::::::::
[warn] :: UNRESOLVED DEPENDENCIES ::
[warn] ::::::::::::::::::::::::::::::::::::::::::::::
[warn] :: com.acme.foo#rest_2.10;1.0-SNAPSHOT: not found
[warn] :: com.acme#foo_2.10;1.0-SNAPSHOT: not found
[warn] ::::::::::::::::::::::::::::::::::::::::::::::
Why does it insist on looking for _2.10 versions of my modules?