我使用Play!2框架使用SBT作为依赖项。我想检索2.1.0-BUILD-SNAPSHOT版本的Spring Data Neo4j
我的ApplicationBuild.scala
(由SBT使用)如下:
import sbt._
import Keys._
import play.Project._
object ApplicationBuild extends Build {
val appName = "webapp"
val appVersion = "1.0-SNAPSHOT"
val appDependencies = Seq(
jdbc,
anorm,
"org.springframework" % "spring-aop" % "3.2.0.RELEASE",
"org.springframework" % "spring-aspects" % "3.2.0.RELEASE",
"org.springframework" % "spring-beans" % "3.2.0.RELEASE",
"org.springframework.data" % "spring-data-commons-core" % "1.4.0.RELEASE",
"org.springframework" % "spring-expression" % "3.2.0.RELEASE",
"org.springframework" % "spring-jdbc" % "3.2.0.RELEASE",
"org.springframework" % "spring-orm" % "3.2.0.RELEASE",
"org.springframework" % "spring-test" % "3.2.0.RELEASE",
"org.springframework" % "spring-tx" % "3.2.0.RELEASE",
"org.springframework.data" % "spring-data-neo4j" % "2.1.0.BUILD-SNAPSHOT" excludeAll(
ExclusionRule(organization = "com.sun.jdmk"),
ExclusionRule(organization = "com.sun.jmx"),
ExclusionRule(organization = "javax.jms")
),
"org.neo4j" % "neo4j" % "1.8.1",
"asm" % "asm-all" % "3.1"
)
val main = play.Project(appName, appVersion, appDependencies).settings(
scalaVersion := "2.10.0",
resolvers += "TAMU Release Repository" at "https://maven.library.tamu.edu/content/repositories/releases/",
resolvers += "Spring Maven SNAPSHOT Repository" at "http://repo.springsource.org/libs-snapshot"
)
}
除了spring-data-neo4j之外,所有的依赖项都下载好了。
会导致以下错误:
warn] ::::::::::::::::::::::::::::::::::::::::::::::
[warn] :: UNRESOLVED DEPENDENCIES ::
[warn] ::::::::::::::::::::::::::::::::::::::::::::::
[warn] :: org.neo4j#neo4j-cypher-dsl;1.8.RC1: not found
[warn] ::::::::::::::::::::::::::::::::::::::::::::::
[error] (*:update) sbt.ResolveException: unresolved dependency: org.neo4j#neo4j-cypher-dsl;1.8.RC1: not found
未找到neo4j-cypher-dsl;1.8.RC1
是否正常?我应该怎样取回它?
我找到了一个解决方法:
添加:resolvers += "Neo4j Cypher DSL Repository" at "http://m2.neo4j.org/content/repositories/releases"
将下载丢失的jar。