Skip to content

Commit

Permalink
Fix typelevel#60 when scalac options specified in ThisBuild scope by …
Browse files Browse the repository at this point in the history
…user are ignored
  • Loading branch information
Ivan Stanislavciuc committed Apr 4, 2022
1 parent 831ae82 commit f1aa0bf
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/main/scala/io/github/davidgregory084/TpolecatPlugin.scala
Original file line number Diff line number Diff line change
Expand Up @@ -120,16 +120,16 @@ object TpolecatPlugin extends AutoPlugin {
tpolecatCiModeEnvVar := "SBT_TPOLECAT_CI",
tpolecatReleaseModeEnvVar := "SBT_TPOLECAT_RELEASE",
tpolecatOptionsMode := {
if (sys.env.get(tpolecatReleaseModeEnvVar.value).nonEmpty) ReleaseMode
else if (sys.env.get(tpolecatCiModeEnvVar.value).nonEmpty) CiMode
else if (sys.env.get(tpolecatDevModeEnvVar.value).nonEmpty) DevMode
if (sys.env.contains(tpolecatReleaseModeEnvVar.value)) ReleaseMode
else if (sys.env.contains(tpolecatCiModeEnvVar.value)) CiMode
else if (sys.env.contains(tpolecatDevModeEnvVar.value)) DevMode
else tpolecatDefaultOptionsMode.value
}
) ++ commandAliases

override def projectSettings: Seq[Setting[_]] = Seq(
Def.derive(
scalacOptions := scalacOptionsFor(scalaVersion.value, tpolecatScalacOptions.value)
scalacOptions ++= scalacOptionsFor(scalaVersion.value, tpolecatScalacOptions.value)
),
tpolecatDevModeOptions := ScalacOptions.default,
Def.derive(
Expand Down

0 comments on commit f1aa0bf

Please sign in to comment.