File tree 1 file changed +6
-2
lines changed
compiler/test-coursier/dotty/tools/coursier
1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -170,12 +170,16 @@ object CoursierScalaTests:
170
170
171
171
/** Get coursier script */
172
172
@ BeforeClass def setup (): Unit =
173
- val ver = execCmd(" uname" )._2.head.replace('L' , 'l' ).replace('D' , 'd' )
173
+ val launcherLocation = " https://github.com/coursier/launchers/raw/master"
174
+ val launcherName = execCmd(" uname" )._2.head.toLowerCase match
175
+ case " linux" => " cs-x86_64-pc-linux"
176
+ case " darwin" => " cs-x86_64-apple-darwin"
177
+ case other => fail(s " Unsupported OS for coursier launcher: $other" )
174
178
175
179
def runAndCheckCmd (cmd : String , options : String * ): Unit =
176
180
val (code, out) = execCmd(cmd, options* )
177
181
if code != 0 then
178
182
fail(s " Failed to run $cmd ${options.mkString(" " )}, exit code: $code, output: ${out.mkString(" \n " )}" )
179
183
180
- runAndCheckCmd(" curl" , s " -fLo cs https://git.io/coursier-cli- $ver " )
184
+ runAndCheckCmd(" curl" , s " -fLo cs $launcherLocation / $launcherName " )
181
185
runAndCheckCmd(" chmod" , " +x cs" )
You can’t perform that action at this time.
0 commit comments