From dec444b3107bfe4da95e7fc15487174d06ea0307 Mon Sep 17 00:00:00 2001 From: Hamza REMMAL Date: Fri, 19 Jul 2024 13:51:35 +0200 Subject: [PATCH 1/2] Drop previous scala-cli management on windows --- dist/bin-native-overrides/cli-common-platform | 15 +------------ .../cli-common-platform.bat | 21 +------------------ project/Build.scala | 6 +----- 3 files changed, 3 insertions(+), 39 deletions(-) diff --git a/dist/bin-native-overrides/cli-common-platform b/dist/bin-native-overrides/cli-common-platform index 1a11c770f91a..49803d6282c5 100644 --- a/dist/bin-native-overrides/cli-common-platform +++ b/dist/bin-native-overrides/cli-common-platform @@ -1,16 +1,3 @@ #!/usr/bin/env bash -if [[ ${cygwin-} || ${mingw-} || ${msys-} ]]; then - SCALA_CLI_VERSION="" - # iterate through lines in VERSION_SRC - while IFS= read -r line; do - # if line starts with "version:=" then extract the version - if [[ "$line" == cli_version:=* ]]; then - SCALA_CLI_VERSION="${line#cli_version:=}" - break - fi - done < "$PROG_HOME/EXTRA_PROPERTIES" - SCALA_CLI_CMD_BASH=("\"$PROG_HOME/bin/scala-cli\"" "--cli-version \"$SCALA_CLI_VERSION\"") -else - SCALA_CLI_CMD_BASH=("\"$PROG_HOME/bin/scala-cli\"") -fi +SCALA_CLI_CMD_BASH=("\"$PROG_HOME/bin/scala-cli\"") diff --git a/dist/bin-native-overrides/cli-common-platform.bat b/dist/bin-native-overrides/cli-common-platform.bat index d1c4f1c4716b..24ab08086007 100644 --- a/dist/bin-native-overrides/cli-common-platform.bat +++ b/dist/bin-native-overrides/cli-common-platform.bat @@ -1,22 +1,3 @@ @echo off -setlocal enabledelayedexpansion - -set "_SCALA_CLI_VERSION=" -@rem read for cli_version:=_SCALA_CLI_VERSION in EXTRA_PROPERTIES file -FOR /F "usebackq delims=" %%G IN ("%_PROG_HOME%\EXTRA_PROPERTIES") DO ( - SET "line=%%G" - IF "!line:~0,13!"=="cli_version:=" ( - SET "_SCALA_CLI_VERSION=!line:~13!" - GOTO :foundCliVersion - ) -) - -@REM we didn't find it, so we should fail -echo "ERROR: cli_version not found in EXTRA_PROPERTIES file" -exit /b 1 - -:foundCliVersion -endlocal & set "SCALA_CLI_VERSION=%_SCALA_CLI_VERSION%" - -set SCALA_CLI_CMD_WIN="%_PROG_HOME%\bin\scala-cli.exe" "--cli-version" "%SCALA_CLI_VERSION%" +set SCALA_CLI_CMD_WIN="%_PROG_HOME%\bin\scala-cli.exe" diff --git a/project/Build.scala b/project/Build.scala index 23a541595d8e..8a4f523a5937 100644 --- a/project/Build.scala +++ b/project/Build.scala @@ -119,8 +119,6 @@ object Build { /** Version of Scala CLI to download */ val scalaCliLauncherVersion = "1.4.0" - /** Version of Scala CLI to download (on Windows - last known validated version) */ - val scalaCliLauncherVersionWindows = "1.4.0" /** Version of Coursier to download for initializing the local maven repo of Scala command */ val coursierJarVersion = "2.1.10" @@ -2176,10 +2174,8 @@ object Build { packArchiveName := (dist / packArchiveName).value + "-x86_64-pc-win32", republishBinOverrides += (dist / baseDirectory).value / "bin-native-overrides", republishFetchCoursier := (dist / republishFetchCoursier).value, - republishExtraProps += ("cli_version" -> scalaCliLauncherVersion), - mappings += (republishRepo.value / "EXTRA_PROPERTIES" -> "EXTRA_PROPERTIES"), republishLaunchers += - ("scala-cli.exe" -> s"zip+https://github.com/VirtusLab/scala-cli/releases/download/v$scalaCliLauncherVersionWindows/scala-cli-x86_64-pc-win32.zip!/scala-cli.exe") + ("scala-cli.exe" -> s"zip+https://github.com/VirtusLab/scala-cli/releases/download/v$scalaCliLauncherVersion/scala-cli-x86_64-pc-win32.zip!/scala-cli.exe") ) lazy val `dist-linux-x86_64` = project.in(file("dist/linux-x86_64")).asDist(Bootstrapped) From 3a60d5cb18c72564e02ede45d9597ba120811817 Mon Sep 17 00:00:00 2001 From: Hamza REMMAL Date: Fri, 19 Jul 2024 13:52:18 +0200 Subject: [PATCH 2/2] Bump scala-cli to 1.4.1 --- project/Build.scala | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/project/Build.scala b/project/Build.scala index 8a4f523a5937..648dc9c41b5b 100644 --- a/project/Build.scala +++ b/project/Build.scala @@ -118,7 +118,7 @@ object Build { val mimaPreviousLTSDottyVersion = "3.3.0" /** Version of Scala CLI to download */ - val scalaCliLauncherVersion = "1.4.0" + val scalaCliLauncherVersion = "1.4.1" /** Version of Coursier to download for initializing the local maven repo of Scala command */ val coursierJarVersion = "2.1.10"