据我所知,Play 2.5.4需要scala 2.11或更高版本。
我的Play似乎是从&project \ target \ scala-2.10 \ sbt-0.13 \ resource_managed \ main \ sbt \ sbt.builds中读取的,'
为什么在安装2.11时读取scala 2.10?
有人可以帮忙吗?
帮助告诉玩家必须使用Scala 2.11而不是2.10。
error:
[info] Set current project to root (in build file:/)
java.lang.RuntimeException: No main class detected.
at scala.sys.package$.error(package.scala:27)
[trace] Stack trace suppressed: run last compile:run for the full output.
[error] (compile:run) No main class detected.
[error] Total time: 0 s, completed 6 Jul, 2016 2:20:54 PM
答案 0 :(得分:0)
在您的文件build.sbt
中,您应该添加以下行:
scalaVersion := "2.11.8"
答案 1 :(得分:0)
在build.scala中添加scalaVersion =" 2.11.8"