Skip to content

Commit 312b6c1

Browse files
authored
Merge pull request #4129 from Gedochao/maintenance/misccherrypicks0213
Cherry pick #4073, #4072 & #4123 to the `stable` branch
2 parents 5e42e93 + 0af2d8c commit 312b6c1

11 files changed

Lines changed: 160 additions & 548 deletions

File tree

.github/workflows/ci.yml

Lines changed: 135 additions & 523 deletions
Large diffs are not rendered by default.

modules/cli/src/main/scala/scala/cli/commands/shared/SharedJvmOptions.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ final case class SharedJvmOptions(
1818
javaHome: Option[String] = None,
1919

2020
@Group(HelpGroup.Java.toString)
21-
@HelpMessage("Use a specific JVM, such as `14`, `adopt:11`, or `graalvm:21`, or `system`. " +
21+
@HelpMessage("Use a specific JVM, such as `14`, `temurin:11`, or `graalvm:21`, or `system`. " +
2222
"scala-cli uses [coursier](https://get-coursier.io/) to fetch JVMs, so you can use `cs java --available` to list the available JVMs.")
2323
@ValueDescription("jvm-name")
2424
@Tag(tags.should)

modules/directives/src/main/scala/scala/build/preprocessing/directives/Jvm.scala

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,14 @@ import scala.cli.commands.SpecificationLevel
88

99
@DirectiveGroupName("JVM version")
1010
@DirectiveExamples("//> using jvm 11")
11-
@DirectiveExamples("//> using jvm adopt:11")
11+
@DirectiveExamples("//> using jvm temurin:11")
1212
@DirectiveExamples("//> using jvm graalvm:21")
1313
@DirectiveUsage(
1414
"//> using jvm _value_",
1515
"`//> using jvm` _value_"
1616
)
1717
@DirectiveDescription(
18-
"Use a specific JVM, such as `14`, `adopt:11`, or `graalvm:21`, or `system`. " +
18+
"Use a specific JVM, such as `14`, `temurin:11`, or `graalvm:21`, or `system`. " +
1919
"scala-cli uses [coursier](https://get-coursier.io/) to fetch JVMs, so you can use `cs java --available` to list the available JVMs."
2020
)
2121
@DirectiveLevel(SpecificationLevel.SHOULD)

modules/directives/src/main/scala/scala/build/preprocessing/directives/Toolkit.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ import scala.cli.commands.SpecificationLevel
1919
"//> using toolkit _version_",
2020
"""`//> using toolkit` _version_
2121
|
22-
|//> using test.toolkit` _version_
22+
|`//> using test.toolkit` _version_
2323
|""".stripMargin
2424
)
2525
@DirectiveDescription(

modules/integration/src/test/scala/scala/cli/integration/ExportJsonTestDefinitions.scala

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ abstract class ExportJsonTestDefinitions extends ScalaCliSuite with TestScalaVer
4343

4444
val exportJsonProc =
4545
// Test --power placed after subcommand name
46-
os.proc(TestUtil.cli, "export", "--power", "--json", ".", "--jvm", "adopt:11")
46+
os.proc(TestUtil.cli, "export", "--power", "--json", ".", "--jvm", "temurin:11")
4747
.call(cwd = root)
4848

4949
val jsonContents = readJson(exportJsonProc.out.text())
@@ -53,7 +53,7 @@ abstract class ExportJsonTestDefinitions extends ScalaCliSuite with TestScalaVer
5353
|"projectVersion":"1.1.2",
5454
|"scalaVersion":"${Constants.scala3Next}",
5555
|"platform":"JVM",
56-
|"jvmVersion":"adopt:11",
56+
|"jvmVersion":"temurin:11",
5757
|"scopes": {
5858
| "main": {
5959
| "sources": ["${withEscapedBackslashes(root / "Main.scala")}"],

website/docs/reference/cli-options.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -673,7 +673,7 @@ Set the Java home directory
673673

674674
Aliases: `-j`
675675

676-
Use a specific JVM, such as `14`, `adopt:11`, or `graalvm:21`, or `system`. scala-cli uses [coursier](https://get-coursier.io/) to fetch JVMs, so you can use `cs java --available` to list the available JVMs.
676+
Use a specific JVM, such as `14`, `temurin:11`, or `graalvm:21`, or `system`. scala-cli uses [coursier](https://get-coursier.io/) to fetch JVMs, so you can use `cs java --available` to list the available JVMs.
677677

678678
### `--jvm-index`
679679

website/docs/reference/directives.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -188,14 +188,14 @@ Exclude sources from the project
188188

189189
### JVM version
190190

191-
Use a specific JVM, such as `14`, `adopt:11`, or `graalvm:21`, or `system`. scala-cli uses [coursier](https://get-coursier.io/) to fetch JVMs, so you can use `cs java --available` to list the available JVMs.
191+
Use a specific JVM, such as `14`, `temurin:11`, or `graalvm:21`, or `system`. scala-cli uses [coursier](https://get-coursier.io/) to fetch JVMs, so you can use `cs java --available` to list the available JVMs.
192192

193193
`//> using jvm` _value_
194194

195195
#### Examples
196196
`//> using jvm 11`
197197

198-
`//> using jvm adopt:11`
198+
`//> using jvm temurin:11`
199199

200200
`//> using jvm graalvm:21`
201201

@@ -685,7 +685,7 @@ Use a toolkit as dependency (not supported in Scala 2.12), 'default' version for
685685

686686
`//> using toolkit` _version_
687687

688-
//> using test.toolkit` _version_
688+
`//> using test.toolkit` _version_
689689

690690

691691
#### Examples

website/docs/reference/scala-command/cli-options.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -598,7 +598,7 @@ Aliases: `-j`
598598

599599
`SHOULD have` per Scala Runner specification
600600

601-
Use a specific JVM, such as `14`, `adopt:11`, or `graalvm:21`, or `system`. scala-cli uses [coursier](https://get-coursier.io/) to fetch JVMs, so you can use `cs java --available` to list the available JVMs.
601+
Use a specific JVM, such as `14`, `temurin:11`, or `graalvm:21`, or `system`. scala-cli uses [coursier](https://get-coursier.io/) to fetch JVMs, so you can use `cs java --available` to list the available JVMs.
602602

603603
### `--jvm-index`
604604

website/docs/reference/scala-command/directives.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -217,14 +217,14 @@ Exclude sources from the project
217217

218218
### JVM version
219219

220-
Use a specific JVM, such as `14`, `adopt:11`, or `graalvm:21`, or `system`. scala-cli uses [coursier](https://get-coursier.io/) to fetch JVMs, so you can use `cs java --available` to list the available JVMs.
220+
Use a specific JVM, such as `14`, `temurin:11`, or `graalvm:21`, or `system`. scala-cli uses [coursier](https://get-coursier.io/) to fetch JVMs, so you can use `cs java --available` to list the available JVMs.
221221

222222
`//> using jvm` _value_
223223

224224
#### Examples
225225
`//> using jvm 11`
226226

227-
`//> using jvm adopt:11`
227+
`//> using jvm temurin:11`
228228

229229
`//> using jvm graalvm:21`
230230

@@ -479,7 +479,7 @@ Use a toolkit as dependency (not supported in Scala 2.12), 'default' version for
479479

480480
`//> using toolkit` _version_
481481

482-
//> using test.toolkit` _version_
482+
`//> using test.toolkit` _version_
483483

484484

485485
#### Examples

website/docs/reference/scala-command/runner-specification.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -246,7 +246,7 @@ Set the Java home directory
246246

247247
**--jvm**
248248

249-
Use a specific JVM, such as `14`, `adopt:11`, or `graalvm:21`, or `system`. scala-cli uses [coursier](https://get-coursier.io/) to fetch JVMs, so you can use `cs java --available` to list the available JVMs.
249+
Use a specific JVM, such as `14`, `temurin:11`, or `graalvm:21`, or `system`. scala-cli uses [coursier](https://get-coursier.io/) to fetch JVMs, so you can use `cs java --available` to list the available JVMs.
250250

251251
Aliases: `-j`
252252

@@ -721,7 +721,7 @@ Set the Java home directory
721721

722722
**--jvm**
723723

724-
Use a specific JVM, such as `14`, `adopt:11`, or `graalvm:21`, or `system`. scala-cli uses [coursier](https://get-coursier.io/) to fetch JVMs, so you can use `cs java --available` to list the available JVMs.
724+
Use a specific JVM, such as `14`, `temurin:11`, or `graalvm:21`, or `system`. scala-cli uses [coursier](https://get-coursier.io/) to fetch JVMs, so you can use `cs java --available` to list the available JVMs.
725725

726726
Aliases: `-j`
727727

@@ -1048,7 +1048,7 @@ Set the Java home directory
10481048

10491049
**--jvm**
10501050

1051-
Use a specific JVM, such as `14`, `adopt:11`, or `graalvm:21`, or `system`. scala-cli uses [coursier](https://get-coursier.io/) to fetch JVMs, so you can use `cs java --available` to list the available JVMs.
1051+
Use a specific JVM, such as `14`, `temurin:11`, or `graalvm:21`, or `system`. scala-cli uses [coursier](https://get-coursier.io/) to fetch JVMs, so you can use `cs java --available` to list the available JVMs.
10521052

10531053
Aliases: `-j`
10541054

@@ -1651,7 +1651,7 @@ Set the Java home directory
16511651

16521652
**--jvm**
16531653

1654-
Use a specific JVM, such as `14`, `adopt:11`, or `graalvm:21`, or `system`. scala-cli uses [coursier](https://get-coursier.io/) to fetch JVMs, so you can use `cs java --available` to list the available JVMs.
1654+
Use a specific JVM, such as `14`, `temurin:11`, or `graalvm:21`, or `system`. scala-cli uses [coursier](https://get-coursier.io/) to fetch JVMs, so you can use `cs java --available` to list the available JVMs.
16551655

16561656
Aliases: `-j`
16571657

@@ -2280,7 +2280,7 @@ Set the Java home directory
22802280

22812281
**--jvm**
22822282

2283-
Use a specific JVM, such as `14`, `adopt:11`, or `graalvm:21`, or `system`. scala-cli uses [coursier](https://get-coursier.io/) to fetch JVMs, so you can use `cs java --available` to list the available JVMs.
2283+
Use a specific JVM, such as `14`, `temurin:11`, or `graalvm:21`, or `system`. scala-cli uses [coursier](https://get-coursier.io/) to fetch JVMs, so you can use `cs java --available` to list the available JVMs.
22842284

22852285
Aliases: `-j`
22862286

@@ -2928,7 +2928,7 @@ Set the Java home directory
29282928

29292929
**--jvm**
29302930

2931-
Use a specific JVM, such as `14`, `adopt:11`, or `graalvm:21`, or `system`. scala-cli uses [coursier](https://get-coursier.io/) to fetch JVMs, so you can use `cs java --available` to list the available JVMs.
2931+
Use a specific JVM, such as `14`, `temurin:11`, or `graalvm:21`, or `system`. scala-cli uses [coursier](https://get-coursier.io/) to fetch JVMs, so you can use `cs java --available` to list the available JVMs.
29322932

29332933
Aliases: `-j`
29342934

@@ -3552,7 +3552,7 @@ Set the Java home directory
35523552

35533553
**--jvm**
35543554

3555-
Use a specific JVM, such as `14`, `adopt:11`, or `graalvm:21`, or `system`. scala-cli uses [coursier](https://get-coursier.io/) to fetch JVMs, so you can use `cs java --available` to list the available JVMs.
3555+
Use a specific JVM, such as `14`, `temurin:11`, or `graalvm:21`, or `system`. scala-cli uses [coursier](https://get-coursier.io/) to fetch JVMs, so you can use `cs java --available` to list the available JVMs.
35563556

35573557
Aliases: `-j`
35583558

@@ -4213,7 +4213,7 @@ Set the Java home directory
42134213

42144214
**--jvm**
42154215

4216-
Use a specific JVM, such as `14`, `adopt:11`, or `graalvm:21`, or `system`. scala-cli uses [coursier](https://get-coursier.io/) to fetch JVMs, so you can use `cs java --available` to list the available JVMs.
4216+
Use a specific JVM, such as `14`, `temurin:11`, or `graalvm:21`, or `system`. scala-cli uses [coursier](https://get-coursier.io/) to fetch JVMs, so you can use `cs java --available` to list the available JVMs.
42174217

42184218
Aliases: `-j`
42194219

@@ -4934,7 +4934,7 @@ Set the Java home directory
49344934

49354935
**--jvm**
49364936

4937-
Use a specific JVM, such as `14`, `adopt:11`, or `graalvm:21`, or `system`. scala-cli uses [coursier](https://get-coursier.io/) to fetch JVMs, so you can use `cs java --available` to list the available JVMs.
4937+
Use a specific JVM, such as `14`, `temurin:11`, or `graalvm:21`, or `system`. scala-cli uses [coursier](https://get-coursier.io/) to fetch JVMs, so you can use `cs java --available` to list the available JVMs.
49384938

49394939
Aliases: `-j`
49404940

@@ -5911,7 +5911,7 @@ Set the Java home directory
59115911

59125912
**--jvm**
59135913

5914-
Use a specific JVM, such as `14`, `adopt:11`, or `graalvm:21`, or `system`. scala-cli uses [coursier](https://get-coursier.io/) to fetch JVMs, so you can use `cs java --available` to list the available JVMs.
5914+
Use a specific JVM, such as `14`, `temurin:11`, or `graalvm:21`, or `system`. scala-cli uses [coursier](https://get-coursier.io/) to fetch JVMs, so you can use `cs java --available` to list the available JVMs.
59155915

59165916
Aliases: `-j`
59175917

0 commit comments

Comments
 (0)