File tree 1 file changed +4
-4
lines changed
1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -106,14 +106,14 @@ object MainGenericRunner {
106
106
process(tail, settings.withExecuteMode(ExecuteMode .Run ).withTargetToRun(fqName))
107
107
case (" -cp" | " -classpath" | " --class-path" ) :: cp :: tail =>
108
108
val globdir = cp.replaceAll(" [\\\\ /][^\\\\ /]*$" , " " ) // slash/backslash agnostic
109
- val (tailargs, cpstr) = if globdir.nonEmpty && classpathSeparator != " ;" || cp.contains(classpathSeparator) then
110
- (tail, cp)
111
- else
112
- // combine globbed classpath entries into a classpath
109
+ val (tailargs, cpstr) = if globdir.nonEmpty && ! cp.contains(classpathSeparator) then
110
+ // globdir is wildcard directory for globbed jar files, reconstruct the intended classpath
113
111
val jarfiles = cp :: tail
114
112
val cpfiles = jarfiles.takeWhile( f => f.startsWith(globdir) && ((f.toLowerCase.endsWith(" .jar" ) || f.endsWith(" .zip" ))) )
115
113
val tailargs = jarfiles.drop(cpfiles.size)
116
114
(tailargs, cpfiles.mkString(classpathSeparator))
115
+ else
116
+ (tail, cp)
117
117
118
118
process(tailargs, settings.copy(classPath = settings.classPath ++ cpstr.split(classpathSeparator).filter(_.nonEmpty)))
119
119
You can’t perform that action at this time.
0 commit comments