File tree 5 files changed +6
-23
lines changed
5 files changed +6
-23
lines changed Original file line number Diff line number Diff line change @@ -157,7 +157,7 @@ object MainGenericRunner {
157
157
process(tail, newSettings.withResidualArgs(arg))
158
158
159
159
def main (args : Array [String ]): Unit =
160
- val scalaOpts = envOrNone(" SCALA_OPTS" ).toArray.flatMap(_.split(" " ))
160
+ val scalaOpts = envOrNone(" SCALA_OPTS" ).toArray.flatMap(_.split(" " )).filter(_.nonEmpty)
161
161
val allArgs = scalaOpts ++ args
162
162
val settings = process(allArgs.toList, Settings ())
163
163
if settings.exitCode != 0 then System .exit(settings.exitCode)
Original file line number Diff line number Diff line change 1
- #!dist/target/pack/ bin/scala -classpath dist/target/pack/lib/*
1
+ #!/usr/bin/env -S bin/scala -classpath ' dist/target/pack/lib/*'
2
2
3
3
import java .nio .file .Paths
4
4
Original file line number Diff line number Diff line change 1
- #!bin/scala -classpath 'dist/target/pack/lib/*'
1
+ #!/usr/bin/env -S bin/scala -classpath 'dist/target/pack/lib/*'
2
2
3
3
// won't compile unless the hashbang line sets classpath
4
4
import org .jline .terminal .Terminal
Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -41,15 +41,15 @@ class ClasspathTests:
41
41
42
42
cmd.foreach { printf(" [%s]\n " , _) }
43
43
44
- // test script reports the classpath it sees
44
+ // test script reports the classpath it sees
45
45
val scriptOutput = exec(cmd:_* )
46
46
val scriptCwd = findTaggedLine(" cwd" , scriptOutput)
47
47
printf(" script ran in directory [%s]\n " , scriptCwd)
48
48
val scriptCp = findTaggedLine(" classpath" , scriptOutput)
49
49
50
50
val hashbangClasspathJars = scriptCp.split(psep).map { _.getName }.sorted.distinct
51
51
val packlibJars = listJars(s " $scriptCwd/ $packLibDir" ).sorted.distinct
52
-
52
+
53
53
printf(" %d jar files in dist/target/pack/lib\n " , packlibJars.size)
54
54
printf(" %d test script jars in classpath\n " , hashbangClasspathJars.size)
55
55
@@ -78,7 +78,7 @@ class ClasspathTests:
78
78
79
79
cmd.foreach { printf(" [%s]\n " , _) }
80
80
81
- // test script reports the classpath it sees
81
+ // test script reports the classpath it sees
82
82
val scriptOutput = exec(cmd:_* )
83
83
val scriptCp = findTaggedLine(" unglobbed classpath" , scriptOutput)
84
84
val classpathJars = scriptCp.split(psep).map { _.getName }.sorted.distinct
You can’t perform that action at this time.
0 commit comments