Version(s)
1.5.4 and 4ab3227
Describe the bug
When passing a relative path to --exclude, the project root is used to calculate the resulting absolute path, rather than the current working directory.
To Reproduce
.
├── subdir
│ ├── project.scala
│ └── subsubdir
│ └── Whatever.scala
└── subdir2
└── Something.scala
when running
the project root will be at ./subdir.
Let's say project.scala includes ./subdir2/Something.scala.
//> using file ../subdir2/Something.scala
Now, running scala-cli from .:
scala-cli run subdir --exclude subdir2/Something.scala
This won't actually exclude subdir2/Something.scala.
However, this will:
scala-cli run subdir --exclude ../subdir2/Something.scala
Expected behaviour
--exclude should use the current working directory for calculating relative paths.