我确实有我自己的插件,我用'publish-local'在本地发布。可以使用以前版本的 sbt 在其他项目中解析该插件,但它不再工作。
build.sbt of the plugin
sbtPlugin := true
name := "sumosim-webstart"
organization := "net.entelijan"
version := "1.3"
scalaVersion := "2.10.0"
crossPaths := false
publishTo := Some("entelijan-repo" at "http://entelijan.net/artifactory/repositories/libs-ivy-local/")
credentials += Credentials("Artifactory Realm", "entelijan.net", "xxxx", "xxxx")
//scalacOptions ++= Seq("-deprecation", "-unchecked")
那是 sbt publish-local 产生的输出
[exec] [info] Packaging /home/wolfi/prj/sumosim/sumosim-pom/sumosim-webstart/target/sbt-0.12/sumosim-webstart-1.3-javadoc.jar ...
[exec] [info] Done packaging.
[exec] [info] published sumosim-webstart to /home/wolfi/.ivy2/local/net.entelijan/sumosim-webstart/scala_2.10/sbt_0.12/1.3/poms/sumosim-webstart.pom
[exec] [info] published sumosim-webstart to /home/wolfi/.ivy2/local/net.entelijan/sumosim-webstart/scala_2.10/sbt_0.12/1.3/jars/sumosim-webstart.jar
[exec] [info] published sumosim-webstart to /home/wolfi/.ivy2/local/net.entelijan/sumosim-webstart/scala_2.10/sbt_0.12/1.3/srcs/sumosim-webstart-sources.jar
[exec] [info] published sumosim-webstart to /home/wolfi/.ivy2/local/net.entelijan/sumosim-webstart/scala_2.10/sbt_0.12/1.3/docs/sumosim-webstart-javadoc.jar
[exec] [info] published ivy to /home/wolfi/.ivy2/local/net.entelijan/sumosim-webstart/scala_2.10/sbt_0.12/1.3/ivys/ivy.xml
那就是我要使用插件的plugin.sbt:
resolvers ++= Seq(
"typesave" at "http://repo.typesafe.com/typesafe/releases",
"sbt-idea-repo" at "http://mpeltonen.github.com/maven/",
"entelijan" at "http://entelijan.net/artifactory/repo/"
)
addSbtPlugin("com.typesafe.sbteclipse" % "sbteclipse-plugin" % "2.0.0")
addSbtPlugin("net.entelijan" % "sumosim-webstart" % "1.3")
最后我得到的错误信息
[exec] [error] (*:update) sbt.ResolveException: unresolved dependency: net.entelijan#sumosim-webstart;1.3: not found
有谁知道为什么这不起作用?