Skip to content

Instantly share code, notes, and snippets.

@joshserrin
Created August 15, 2012 17:50
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save joshserrin/3361920 to your computer and use it in GitHub Desktop.
Save joshserrin/3361920 to your computer and use it in GitHub Desktop.
import sbt._
import Keys._
import sbtassembly.Plugin._
import AssemblyKeys._
object MyBuild extends Build {
val myProject = Project("my-awesome-project", file("."))
.settings(assemblySettings: _*)
.settings(distributionSettings: _*)
def dist = TaskKey[Unit]("dist", "Create a distribution")
def distributionSettings: Seq[Setting[_]] = Seq(
mainClass in assembly := Some("com.cra.testharness.Launch"),
dist <<= (assembly in Compile, name, version) map {
(jar, name, version) => {
// populate some directory with jar and other files...
}
)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment