我有以下项目构建:
import sbt._
import Keys._
object ProjectBuild extends Build {
val buildVersion = "0.1-SNAPSHOT"
val delvingReleases = "Delving Releases Repository" at "http://development.delving.org:8081/nexus/content/repositories/releases"
val delvingSnapshots = "Delving Snapshot Repository" at "http://development.delving.org:8081/nexus/content/repositories/snapshots"
val delvingRepository = if (buildVersion.endsWith("SNAPSHOT")) delvingSnapshots else delvingReleases
lazy val root = Project(
id = "basex-scala-client",
base = file(".")
).settings(
organization := "eu.delving",
version := buildVersion,
resolvers += "BaseX Repository" at "http://files.basex.org/maven",
libraryDependencies += "org.basex" % "basex" % "7.2.1",
libraryDependencies += "org.specs2" %% "specs2" % "1.7.1" % "test",
publishTo := Some(delvingRepository),
credentials += Credentials(Path.userHome / ".ivy2" / ".credentials"),
publishMavenStyle := true
)
}
当我将生成的库包含在另一个项目中时,如下所示:
"eu.delving" %% "basex-scala-client" % "0.1-SNAPSHOT"
我尝试构建该项目,我收到一个错误提示我找不到该项目引用的“org.basex % basex % 7.2.1”库。
我必须去“客户端”项目中添加解析器才能找到库。有没有办法避免这种情况?