I'm trying to use sbt-assembly and am having trouble getting it installed.
Verbatim from the readme I added the project/plugins.sbt with the dependency:
addSbtPlugin("com.eed3si9n" % "sbt-assembly" % "0.8.7")
Then I added a build.sbt file containing exactly what the readme said:
import AssemblyKeys._ // put this at the top of the file
assemblySettings
I get this error when launching sbt:
[error] /Users/me/git/stest/project/Build.scala:29: not found: value assemblySettings [error] .settings(assemblySettings: _*) [error] ^ [error] one error found [error] (compile:compile) Compilation failed
I went back and tried an alternate I saw in another stackoverflow post:
seq(assemblySettings:_*)
Same problem. Any ideas? (Scala 2.10.0)
The sbt-assembly plugin is an SBT plugin for building a single independent fat JAR file with all dependencies included. This is inspired by the popular Maven assembly plugin, which is used to build fat JARs in Maven.
sbt will download Scala for you. If you install sbt-extras (basically just a script) you don't even need to download sbt : it will automatically download the sbt launcher you need. Very handy since you just need to specify sbt. version in your build.
Run the SBT console and then type sbtVersion to check the SBT version, and scalaVersion for the Scala runtime version.
The author of the plugin here. You said you put exactly what build.sbt says, but the error is coming from build.scala. *.sbt file automatically imports several things, so you have to manually import them for build.scala.
For full configuration, see https://github.com/eed3si9n/sbt-assembly-full-config-sample/blob/master/project/builds.scala.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With