12/29/2015 - 1:23 PM

Additional lines to Play's build.sbt

Additional lines to Play's build.sbt

sources in (Compile, doc) := Seq.empty

publishArtifact in (Compile, packageDoc) := false

//Additional JPA configuration
PlayKeys.externalizeResources := false

mappings in Universal += file("conf/base.conf") -> "conf/base.conf"

mappings in Universal += file("conf/prod.conf") -> "conf/prod.conf"
///Use prod.conf as configuration
bashScriptExtraDefines += """if [ ! -f ${app_home}/../conf/prod.conf ]; then
echo "Configuration file: conf/prod.conf not found!"
exit 1
addJava "-Dconfig.file=${app_home}/../conf/prod.conf""""

///Load external logger configuration when packaged. Originally uses the one from the JAR. 
bashScriptExtraDefines +=
  """if [ -f ${app_home}/../conf/logger.xml ]; then
echo "Alternative logger being used"
addJava "-Dlogger.file=${app_home}/../conf/logger.xml"
///Different conf files for test and running
javaOptions in Test += "-Dconfig.file=conf/application.test.conf"

javaOptions in IntegrationTest += "-Dconfig.file=conf/application.test.conf"

//jacoco settings

jacoco.excludes in jacoco.Config := Seq("views*", "*Routes*", "controllers*routes*", "controllers*Reverse*", "controllers*javascript*", "controller*ref*")

parallelExecution in jacoco.Config := false