From 1d4a132d11a514f2d75c6cb861030299f5d11597 Mon Sep 17 00:00:00 2001 From: xuwei-k <6b656e6a69@gmail.com> Date: Sat, 9 Jun 2018 21:09:20 +0900 Subject: fix scalacOptions for latest Scala 2.13.x These options removed or deprecated - https://github.com/scala/scala/commit/ad25805de5c63084348348aabefdf184927806c2 - https://github.com/scala/scala/commit/7d5e0b01c7f645e4f727f704a18f93ce5c69a9dd --- build.sbt | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/build.sbt b/build.sbt index 697b69c..903933f 100644 --- a/build.sbt +++ b/build.sbt @@ -86,14 +86,23 @@ lazy val buildSettings = Seq( "-deprecation", "-feature", "-Xfuture", - "-Xexperimental", "-Ywarn-value-discard", "-Ywarn-dead-code", - "-Ywarn-nullary-unit", "-Ywarn-numeric-widen", - "-Ywarn-inaccessible", - "-Ywarn-adapted-args" ), + scalacOptions ++= { + CrossVersion.partialVersion(scalaVersion.value) match { + case Some((2, v)) if v <= 12 => + Seq( + "-Xexperimental", + "-Ywarn-nullary-unit", + "-Ywarn-inaccessible", + "-Ywarn-adapted-args" + ) + case _ => + Nil + } + }, scmInfo := Some( ScmInfo(url("https://github.com/propensive/magnolia"), "scm:git:git@github.com:propensive/magnolia.git") -- cgit v1.2.3