我确信这很简单,但我还没有弄清楚...
我已经安装了 sbt-launch.jar 和一个执行它的 shell 脚本(名为 sbt< /代码>)。
如何将多个项目放在同一个目录中?
当我运行 sbt
时,会创建并填充目录 project
和 target
,当前项目为 default-XXXXX
。 compile
命令获取顶级目录中的源文件和顶级“lib”目录中的 jar 文件。
如何在同一目录下添加另一个项目?每次我在空目录中运行 sbt
时,它都会创建一个 20+ MB 的 project
目录。
注 1:当我运行 sbt 时,我没有被问到“创建新项目?”或任何其他问题。
注 2:我使用以下网址中的 sbt-launch.jar:http://typesafe.artifactoryonline.com/typesafe/ivy-releases/org.scala-tools.sbt/sbt-launch/0.10.1/sbt-launch.jar
和我'我按照以下网址的说明进行操作:http://code.google.com/p/simple-build-tool/wiki/Setup
I'm sure this is simple, but I haven't figured it out yet...
I've installed sbt-launch.jar
and a shell script to execute it (named sbt
).
How do I put multiple projects in the same directory?
When I run sbt
the directories project
and target
get created and populated, and the current project is default-XXXXX
. The compile
command picks up source files in the top-level directory and jar files in the top-level 'lib' directory.
How do I add another project under the same directory? Every time I run sbt
in an empty directory it creates a 20+ MB project
directory.
Note 1: when I run sbt
I an not getting asked "Create new project?" or any other questions.
Note 2: I am using sbt-launch.jar from this url: http://typesafe.artifactoryonline.com/typesafe/ivy-releases/org.scala-tools.sbt/sbt-launch/0.10.1/sbt-launch.jar
and I'm following the instructions at: http://code.google.com/p/simple-build-tool/wiki/Setup
发布评论
评论(1)
找到答案(对于 sbt 0.10.1):
创建如下所示的文件
project/Build.scala
:这将创建三个项目“root”(在顶级目录中)、“proj1” (在子目录“dir1”中)和“proj2”(在子目录“dir2”中)
有关详细信息,请参阅https://github.com/harrah/xsbt/wiki/Full-Configuration
Found the answer (for sbt 0.10.1):
Create the file
project/Build.scala
that looks like this:This creates three projects 'root' (in the top-level directory), 'proj1' (in the sub-directory 'dir1') and 'proj2' (in the sub-directory 'dir2')
For more info, see https://github.com/harrah/xsbt/wiki/Full-Configuration