Skip to content

Commit 2a2de2d

Browse files
Merge pull request #6187 from dotty-staging/community-build-cmd
Run the community build CI with the correct sbt wrapper
2 parents 5e31e59 + 17e78ad commit 2a2de2d

File tree

4 files changed

+16
-9
lines changed

4 files changed

+16
-9
lines changed

.drone.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,8 +40,7 @@ pipeline:
4040
commands:
4141
- cp -R . /tmp/3/ && cd /tmp/3/
4242
- git submodule update --init --recursive --jobs 7
43-
- export PATH=/tmp/4/project/scripts:$PATH
44-
- sbt community-build/test
43+
- ./project/scripts/sbt community-build/test
4544

4645
test_sbt:
4746
group: test

community-build/test/scala/dotty/communitybuild/CommunityBuildTest.scala

Lines changed: 13 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -58,11 +58,19 @@ class CommunityBuildTest {
5858
val pluginFilePath = communitybuildDir.resolve("sbt-dotty-sbt").toAbsolutePath().toString()
5959

6060
// Run the sbt command with the compiler version and sbt plugin set in the build
61-
val arguments = extraSbtArgs ++ Seq(
62-
"-sbt-version", "1.2.7",
63-
s"--addPluginSbtFile=$pluginFilePath",
64-
s";clean ;set updateOptions in Global ~= (_.withLatestSnapshots(false)) ;++$compilerVersion! $testCommand"
65-
)
61+
val arguments = {
62+
val sbtProps = Option(System.getProperty("sbt.ivy.home")) match {
63+
case Some(ivyHome) =>
64+
Seq(s"-Dsbt.ivy.home=$ivyHome")
65+
case _ =>
66+
Seq()
67+
}
68+
extraSbtArgs ++ sbtProps ++ Seq(
69+
"-sbt-version", "1.2.7",
70+
s"--addPluginSbtFile=$pluginFilePath",
71+
s";clean ;set updateOptions in Global ~= (_.withLatestSnapshots(false)) ;++$compilerVersion! $testCommand"
72+
)
73+
}
6674

6775
val exitCode = exec("sbt", arguments: _*)
6876

0 commit comments

Comments
 (0)