Created
May 8, 2012 05:30
-
-
Save yamashiro/2632797 to your computer and use it in GitHub Desktop.
sbtのマルチプロジェクト構成
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import sbt._ | |
import Keys._ | |
import com.github.retronym.SbtOneJar | |
object AggregateBuild extends Build { | |
val specs = "org.specs2" %% "specs2" % "1.9" % "test" | |
val specsResolver = Seq("snapshots" at "http://oss.sonatype.org/content/repositories/snapshots", | |
"releases" at "http://oss.sonatype.org/content/repositories/releases") | |
lazy val dependencies = Seq(specs) | |
def standardSettings = Seq( | |
exportJars := true, | |
scalaVersion := "2.9.2", | |
libraryDependencies ++= dependencies, | |
resolvers ++= specsResolver | |
) ++ Defaults.defaultSettings | |
lazy val root = Project(id = "root", | |
base = file(".")) aggregate(core, sample) | |
lazy val core = Project("core", | |
file("core"), | |
settings = standardSettings) | |
lazy val sample = Project("sample", | |
file("sample"), | |
settings = standardSettings ++ SbtOneJar.oneJarSettings | |
) dependsOn (core) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment