【发布时间】:2012-03-21 22:46:15
【问题描述】:
我在构建和运行 SBT 项目时遇到问题。
“协议”项目被多个模块使用,包括“守护进程”。
“守护进程”项目应打包为可执行 jar。
这样做的“正确”方法是什么?
这是我的 Build.scala:
object MyBuild extends Build {
lazy val buildSettings = Seq(
organization := "com.example",
version := "1.0-SNAPSHOT",
scalaVersion := "2.9.1"
)
lazy val root = Project(
id = "MyProject",
base = file("."),
aggregate = Seq(protocol, daemon)
)
lazy val protocol = Project(
id = "Protocol",
base = file("Protocol")
)
lazy val daemon = Project(
id = "Daemon",
base = file("Daemon"),
dependencies = Seq(protocol)
)
// (plus more projects)
【问题讨论】: