How to use sbt-assembly?

2019-08-06 20:00发布

问题:

I'm quite new to Scala and sbt and would like to create a fat jar files which includes all the dependency libraries. It looks like the original sbt does not do that and I have to user something like sbt-assembly. However I can't quite figure out how should I install and use it. Can someone elaborate on it for me?

回答1:

Drop this into project/plugins.sbt

addSbtPlugin("com.eed3si9n" % "sbt-assembly" % "0.13.0")

That should let you run sbt assembly now. Then you can solve merge conflicts in your build.sbt or Build.scala.



标签: scala sbt