tmi*_*lei 3 sbt playframework playframework-2.0
我想为play-jsonsbt项目添加依赖项.
我在project/plugins.sbt以下位置添加了Typesafe存储库:
resolvers += "Typesafe repository" at "http://repo.typesafe.com/typesafe/releases/"
Run Code Online (Sandbox Code Playgroud)
然后我添加了play-json依赖Build.scala如下:
libraryDependencies += "com.typesafe.play" % "play-json_2.10" % "2.2.1"
Run Code Online (Sandbox Code Playgroud)
有了这个,我得到如下错误:
[warn] module not found: com.typesafe.play#play-json_2.10;2.2.1
[warn] ==== local: tried
[warn] /home/tminglei/.ivy2/local/com.typesafe.play/play-json_2.10/2.2.1/ivys/ivy.xml
[warn] ==== sonatype-snapshots: tried
[warn] https://oss.sonatype.org/content/repositories/snapshots/com/typesafe/play/play-json_2.10/2.2.1/play-json_2.10-2.2.1.pom
[warn] ==== public: tried
[warn] http://repo1.maven.org/maven2/com/typesafe/play/play-json_2.10/2.2.1/play-json_2.10-2.2.1.pom
[info] Resolving org.scala-tools.testing#test-interface;0.5 ...
[warn] ::::::::::::::::::::::::::::::::::::::::::::::
[warn] :: UNRESOLVED DEPENDENCIES ::
[warn] ::::::::::::::::::::::::::::::::::::::::::::::
[warn] :: com.typesafe.play#play-json_2.10;2.2.1: not found
[warn] ::::::::::::::::::::::::::::::::::::::::::::::
Run Code Online (Sandbox Code Playgroud)
如何整理出来?
由于依赖项不是插件,因此您只应将resolvers设置添加到build.sbt项目的主目录中.
resolvers += "Typesafe repository" at "http://repo.typesafe.com/typesafe/releases/"
Run Code Online (Sandbox Code Playgroud)
project/*.scala这样一个简单的配置你真的不需要文件.
| 归档时间: |
|
| 查看次数: |
3381 次 |
| 最近记录: |