Skip to content

Commit

Permalink
Add sensible scalac options
Browse files Browse the repository at this point in the history
  • Loading branch information
mdedetrich committed Feb 14, 2024
1 parent b80efcf commit 447e0ee
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -104,3 +104,20 @@ ThisBuild / githubWorkflowOSes := Seq("ubuntu-latest", "macos-latest", "windows-

ThisBuild / githubWorkflowJavaVersions := Seq(
JavaSpec.temurin("8"))

ThisBuild / scalacOptions ++= List(
"-unchecked",
"-deprecation",
"-language:_",
"-encoding",
"UTF-8")

ThisBuild / scalacOptions ++= {
if (insideCI.value) {
val log = sLog.value
log.info("Running in CI, enabling Scala2 optimizer")
Seq(
"-opt-inline-from:<sources>",
"-opt:l:inline")
} else Nil
}

0 comments on commit 447e0ee

Please sign in to comment.