我有一个项目/ Generate.scala,它生成一些目标为sourceManaged的Scala代码。 Generate.scala有自己的依赖项。从sbt文档中,似乎这些依赖项应该进入project / build.sbt。当我尝试这个时,sbt停止解析我在project / plugins.sbt中声明的插件。
声明这些依赖项的正确方法是什么?我应该如何从概念上考虑元构建?看起来我误解了"sbt is recursive."
项目/ build.sbt:
scalaVersion in ThisBuild:= "2.12.2"
resolvers += Resolver.sonatypeRepo("releases")
resolvers += Resolver.bintrayRepo("scalameta", "maven")
libraryDependencies += "org.scalameta" %% "scalameta" % "1.7.0"
项目/ plugins.sbt:
addSbtPlugin("com.earldouglas" % "xsbt-web-plugin" % "3.0.1")
addSbtPlugin("io.get-coursier" % "sbt-coursier" % "1.0.0-M15")
addSbtPlugin("org.scala-js" % "sbt-scalajs" % "0.6.16")
addSbtPlugin("com.thesamet" % "sbt-protoc" % "0.99.6" exclude ("com.trueaccord.scalapb", "protoc-bridge_2.10"))
libraryDependencies += "com.trueaccord.scalapb" %% "compilerplugin-shaded" % "0.6.0-pre3"