Skip to content

Commit 07e9106

Browse files
committed
convert relative path to absolute before getParent
1 parent 767abe1 commit 07e9106

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

compiler/src/dotty/tools/scripting/Main.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ object Main:
5252
val javaClasspath = sys.props("java.class.path")
5353
val runtimeClasspath = s"${classpath}$pathsep$javaClasspath"
5454

55-
val jarTargetDir: Path = Option(scriptFile.toPath.getParent) match {
55+
val jarTargetDir: Path = Option(scriptFile.toPath.toAbsolutePath.getParent) match {
5656
case None => sys.error(s"no parent directory for script file [$scriptFile]")
5757
case Some(parent) => parent
5858
}

0 commit comments

Comments
 (0)