diff --git a/build.sbt b/build.sbt index 4bd662a9..673861c8 100644 --- a/build.sbt +++ b/build.sbt @@ -5,6 +5,7 @@ ThisBuild / organization := "com.velocidi" ThisBuild / crossScalaVersions := Seq("2.12.18", "2.13.12") ThisBuild / scalaVersion := "2.13.12" +val javaVersion = "11" // Workaround for incompatible scala-xml versions taken from https://github.com/scala/bug/issues/12632. scala-xml 1.x // and scala-xml 2.x are "mostly" binary compatible. @@ -118,6 +119,7 @@ lazy val commonSettings = Seq( "-feature", "-unchecked", "-deprecation", + "-release", javaVersion, "-Xfatal-warnings", "-Ywarn-dead-code") @@ -135,6 +137,10 @@ lazy val commonSettings = Seq( } }, + javacOptions ++= List( + "--release", javaVersion + ), + autoAPIMappings := true, publishTo := sonatypePublishToBundle.value,