Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update scala-library to 2.13.12 #2396

Merged
merged 6 commits into from
Sep 22, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,9 @@ abstract class ReplTestDefinitions(val scalaVersionOpt: Option[String])

private lazy val extraOptions = scalaVersionArgs ++ TestUtil.extraOptions

protected def versionNumberString: String =
if (actualScalaVersion.startsWith("2.")) actualScalaVersion
// Scala 3 gives the 2.13 version it depends on for its standard library.
// Assuming it's the same Scala 3 version as the integration tests here.
else Properties.versionNumberString
private val retrieveScalaVersionCode = if (actualScalaVersion.startsWith("2."))
"scala.util.Properties.versionNumberString"
else "dotty.tools.dotc.config.Properties.simpleVersionString"

test("default dry run") {
TestInputs.empty.fromRoot { root =>
Expand All @@ -26,7 +24,7 @@ abstract class ReplTestDefinitions(val scalaVersionOpt: Option[String])
TestInputs.empty.fromRoot { root =>
val ammArgs = Seq(
"-c",
"""println("Hello" + " from Scala " + scala.util.Properties.versionNumberString)"""
s"""println("Hello" + " from Scala " + $retrieveScalaVersionCode)"""
)
.map {
if (Properties.isWin)
Expand All @@ -40,7 +38,7 @@ abstract class ReplTestDefinitions(val scalaVersionOpt: Option[String])
root
)
val output = res.out.trim()
expect(output == s"Hello from Scala $versionNumberString")
expect(output == s"Hello from Scala $actualScalaVersion")
}
}

Expand All @@ -58,10 +56,10 @@ abstract class ReplTestDefinitions(val scalaVersionOpt: Option[String])
inputs.fromRoot { root =>
val ammArgs = Seq(
"-c",
"""println("Hello" + " from Scala " + scala.util.Properties.versionNumberString)
|val sth = py.module("foo.something")
|py.Dynamic.global.applyDynamicNamed("print")("" -> sth.messageStart, "" -> sth.messageEnd, "flush" -> py.Any.from(true))
|""".stripMargin
s"""println("Hello" + " from Scala " + $retrieveScalaVersionCode)
|val sth = py.module("foo.something")
|py.Dynamic.global.applyDynamicNamed("print")("" -> sth.messageStart, "" -> sth.messageEnd, "flush" -> py.Any.from(true))
|""".stripMargin
)
.map {
if (Properties.isWin)
Expand Down Expand Up @@ -99,7 +97,7 @@ abstract class ReplTestDefinitions(val scalaVersionOpt: Option[String])
ammArgs
).call(cwd = root)
val lines = res.out.trim().linesIterator.toVector
expect(lines == Seq(s"Hello from Scala $versionNumberString", "Hello from ScalaPy"))
expect(lines == Seq(s"Hello from Scala $actualScalaVersion", "Hello from ScalaPy"))
}
}

Expand Down
6 changes: 3 additions & 3 deletions project/deps.sc
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import $file.utils, utils.isArmArchitecture

object Scala {
def scala212 = "2.12.18"
def scala213 = "2.13.11"
def scala213 = "2.13.12"
def runnerScala3 = "3.0.2" // the newest version that is compatible with all Scala 3.x versions
def scala3 = "3.3.1"
val allScala2 = Seq(scala213, scala212)
Expand All @@ -33,7 +33,7 @@ object Scala {

def maxAmmoniteScala212Version = scala212
def maxAmmoniteScala213Version = scala213
def maxAmmoniteScala3Version = "3.2.2"
def maxAmmoniteScala3Version = scala3
lazy val listMaxAmmoniteScalaVersion =
Seq(maxAmmoniteScala212Version, maxAmmoniteScala213Version, maxAmmoniteScala3Version)
lazy val listAllAmmonite = {
Expand Down Expand Up @@ -97,7 +97,7 @@ object Deps {
// DO NOT hardcode a Scala version in this dependency string
// This dependency is used to ensure that Ammonite is available for Scala versions
// that Scala CLI supports.
def ammonite = ivy"com.lihaoyi:::ammonite:2.5.9"
def ammonite = ivy"com.lihaoyi:::ammonite:3.0.0-M0-53-084f7f4e"
def asm = ivy"org.ow2.asm:asm:9.5"
// Force using of 2.13 - is there a better way?
def bloopConfig = ivy"ch.epfl.scala:bloop-config_2.13:1.5.5"
Expand Down
2 changes: 1 addition & 1 deletion website/docs/reference/cli-options.md
Original file line number Diff line number Diff line change
Expand Up @@ -1137,7 +1137,7 @@ Use Ammonite (instead of the default Scala REPL)

Aliases: `--ammonite-ver`

Set the Ammonite version (2.5.9 by default)
Set the Ammonite version (3.0.0-M0-53-084f7f4e by default)

### `--ammonite-arg`

Expand Down
18 changes: 9 additions & 9 deletions website/docs/reference/scala-command/runner-specification.md
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ Aliases: `-P` ,`--plugin`

**--scala-version**

Set the Scala version (3.3.0 by default)
Set the Scala version (3.3.1 by default)

Aliases: `-S` ,`--scala`

Expand Down Expand Up @@ -799,7 +799,7 @@ Aliases: `-P` ,`--plugin`

**--scala-version**

Set the Scala version (3.3.0 by default)
Set the Scala version (3.3.1 by default)

Aliases: `-S` ,`--scala`

Expand Down Expand Up @@ -1344,7 +1344,7 @@ Aliases: `-P` ,`--plugin`

**--scala-version**

Set the Scala version (3.3.0 by default)
Set the Scala version (3.3.1 by default)

Aliases: `-S` ,`--scala`

Expand Down Expand Up @@ -1903,7 +1903,7 @@ Aliases: `-P` ,`--plugin`

**--scala-version**

Set the Scala version (3.3.0 by default)
Set the Scala version (3.3.1 by default)

Aliases: `-S` ,`--scala`

Expand Down Expand Up @@ -2487,7 +2487,7 @@ Aliases: `-P` ,`--plugin`

**--scala-version**

Set the Scala version (3.3.0 by default)
Set the Scala version (3.3.1 by default)

Aliases: `-S` ,`--scala`

Expand Down Expand Up @@ -3059,7 +3059,7 @@ Aliases: `-P` ,`--plugin`

**--scala-version**

Set the Scala version (3.3.0 by default)
Set the Scala version (3.3.1 by default)

Aliases: `-S` ,`--scala`

Expand Down Expand Up @@ -3650,7 +3650,7 @@ Aliases: `-P` ,`--plugin`

**--scala-version**

Set the Scala version (3.3.0 by default)
Set the Scala version (3.3.1 by default)

Aliases: `-S` ,`--scala`

Expand Down Expand Up @@ -4298,7 +4298,7 @@ Aliases: `-P` ,`--plugin`

**--scala-version**

Set the Scala version (3.3.0 by default)
Set the Scala version (3.3.1 by default)

Aliases: `-S` ,`--scala`

Expand Down Expand Up @@ -5153,7 +5153,7 @@ Aliases: `-P` ,`--plugin`

**--scala-version**

Set the Scala version (3.3.0 by default)
Set the Scala version (3.3.1 by default)

Aliases: `-S` ,`--scala`

Expand Down
2 changes: 1 addition & 1 deletion website/docs/reference/scala-versions.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,5 +20,5 @@ it is recommended to update scala-cli.
| 0.1.20 - 1.0.0-RC2 | 3.2.2 | 2.13.10 | 2.12.17 |
| 1.0.0 - 1.0.1 | 3.3.0 | 2.13.10 | 2.12.17 |
| 1.0.1 - 1.0.4 | 3.3.0 | 2.13.11 | 2.12.18 |
| 1.0.4 - current | 3.3.1 | 2.13.11 | 2.12.18 |
| 1.0.5 - current | 3.3.1 | 2.13.12 | 2.12.18 |