How can I add unmanaged JARs in sbt-assembly to the final fat JAR?

Garrett Hall picture Garrett Hall · Sep 11, 2013 · Viewed 18.8k times · Source

My project has dependencies on a JAR file that isn't in Ivy, how can I include it directly in the final JAR output by sbt-assembly?

Answer

Garrett Hall picture Garrett Hall · Sep 11, 2013

Figured out I just have to add them explicitly as unmanaged dependencies in Build.scala, they are not automatically pulled in from the lib folder. Adding this line to settings worked:

unmanagedJars in Compile += file("lib/vertica_jdk_5.jar")