如何在SBT中设置blueeyes项目?

时间:2015-09-03 10:16:31

标签: scala sbt

我在使用SBT设置this项目时遇到了问题。

当我键入sbt run:

时,它不会解析blueeyes依赖关系
[warn]  ::::::::::::::::::::::::::::::::::::::::::::::
[warn]  ::          UNRESOLVED DEPENDENCIES         ::
[warn]  ::::::::::::::::::::::::::::::::::::::::::::::
[warn]  :: com.reportgrid#blueeyes_2.9.1.RC1;0.4.19: not found
[warn]  ::::::::::::::::::::::::::::::::::::::::::::::
[warn]
[warn]  Note: Unresolved dependencies path:
[warn]      com.reportgrid:blueeyes_2.9.1.RC1:0.4.19 (.../blueeyes-example/build.sbt#L19-22)
[warn]        +- com.foo:blueeyes-test-api_2.9.1.RC1:0.1.0
[trace] Stack trace suppressed: run last *:update for the full output.
[error] (*:update) sbt.ResolveException: unresolved dependency: com.reportgrid#blueeyes_2.9.1.RC1;0.4.19: not found

Github上的BlueEyes项目似乎已经放弃,但我希望还有人可以帮我解决这个问题!

1 个答案:

答案 0 :(得分:2)

形成blueeyes存储库的文档,依赖关系应该声明如下:

resolvers ++= Seq(
  "Sonatype" at "http://oss.sonatype.org/content/repositories/public",
  "Typesafe" at "http://repo.typesafe.com/typesafe/releases/"
)

libraryDependencies ++= Seq(
  "com.github.jdegoes" %% "blueeyes-core"  % "0.6.0",
  "com.github.jdegoes" %% "blueeyes-mongo" % "0.6.0",
  "com.github.jdegoes" %% "blueeyes-json"  % "0.6.0",
  "ch.qos.logback" % "logback-classic" % "1.0.0" % "runtime"
)

您的库依赖项看起来有点不同:

libraryDependencies ++= Seq(
  "com.reportgrid" % "blueeyes_2.9.1.RC1" % "0.4.19" % "compile"
)

<强>更新

scala版本需要

scalaVersion := "2.9.1"

而不是

scalaVersion := "2.9.1.RC1"