Skip to content

Commit

Permalink
Test against CI sys prop
Browse files Browse the repository at this point in the history
  • Loading branch information
olafurpg committed Dec 12, 2016
1 parent 4984113 commit 59a358f
Showing 1 changed file with 8 additions and 12 deletions.
20 changes: 8 additions & 12 deletions build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -184,18 +184,14 @@ lazy val `scalafix-sbt` = project.settings(
allSettings,
ScriptedPlugin.scriptedSettings,
sbtPlugin := true,
scriptedLaunchOpts ++=
sys.props
.get("sbt.ivy.home")
.map { x =>
println("X: " + x)
Seq(
s"-Dsbt.ivy.home=$x",
s"-Divy.home=$x"
)
}
.toSeq
.flatten,
scriptedLaunchOpts ++= {
if (sys.props.contains("CI"))
Seq(
s"-Dsbt.ivy.home=/drone/.ivy2/",
s"-Divy.home=/drone/.ivy2/"
)
else Nil
},
scripted := scripted.dependsOn(publishedArtifacts: _*).evaluated,
scalaVersion := "2.10.5",
moduleName := "sbt-scalafix",
Expand Down

0 comments on commit 59a358f

Please sign in to comment.