Skip to content

Instantly share code, notes, and snippets.

@reynoldsm88
Created November 9, 2020 19:55
Show Gist options
  • Save reynoldsm88/ab0b5bf11ed35d46b2d35698e1c52e36 to your computer and use it in GitHub Desktop.
Save reynoldsm88/ab0b5bf11ed35d46b2d35698e1c52e36 to your computer and use it in GitHub Desktop.
sbt collect jars?
// https://stackoverflow.com/questions/5564690/tell-sbt-to-collect-all-my-dependencies-together
val libraryJarPath = outputPath / "lib"
def collectJarsTask = {
val jars = mainDependencies.libraries +++ mainDependencies.scalaJars
FileUtilities.copyFlat(jars.get, libraryJarPath, log)
}
lazy val collectJars = task { collectJarsTask; None } dependsOn(compile)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment