I have a little bit odd setup. My Java sources are located at
/src
There are .properties
files next to some Java classes. I want them to be packaged to final jar.
Scala sources and resources follow SBT convention and are located at
/srcnew/main/[scala|resources]
Here is how my build.scala
looks like
sourceDirectory := baseDirectory.value / "srcnew",
unmanagedResourceDirectories in Compile := Seq(baseDirectory.value / "src"),
includeFilter in unmanagedResources := "*.properties",
javaSource in Compile := baseDirectory.value / "src",
Even though resourceDirectory
still points to /srcnew/main/resources
resources don't make it to final jar (built with sbt-assembly).
I also tried
unmanagedResourceDirectories := Seq(baseDirectory.value / "src", baseDirectory.value / "srcnew/main/resources"),
and surprisingly it doesn't help either.