Files
sbt/notes/2.0.0/migration.md
T
Jozef Koval ff2a76e769 [2.0.x] fix: Make forked run inherit sbt's working directory (#9442)
forked run used the project's baseDirectory as the working directory, while non-forked execution inherits sbt's own working directory — so toggling fork silently changed how relative paths resolved.

forked run (and forked console) now inherit sbt's working directory, consistent with non-forked execution and `sbtn` expectations.
2026-07-26 15:49:44 -04:00

508 B

Forked run working directory

Forked run no longer runs in the project's baseDirectory; it inherits sbt's working directory, matching non-forked behavior. Forked test is unchanged. To restore the sbt 1.x behavior:

Compile / run / forkOptions := Def.uncached(
  (Compile / run / forkOptions).value.withWorkingDirectory(Some(baseDirectory.value))
)

files extension on Classpath

+ given FileConverter = fileConverter.value
  val cp = (Compile / classpath).value.files