set global base directory to a local directory in scripted tests

This commit is contained in:
Mark Harrah 2011-07-14 08:05:30 -04:00
parent dcedc57ad7
commit 37a404e482
1 changed files with 2 additions and 1 deletions

View File

@ -37,7 +37,8 @@ final class SbtHandler(directory: File, launcher: File, log: Logger, server: IPC
def newRemote =
{
val launcherJar = launcher.getAbsolutePath
val args = "java" :: "-jar" :: launcherJar :: "loadp" :: ( "<" + server.port) :: Nil
val globalBase = "-Dsbt.global.base=" + (new File(directory, "global")).getAbsolutePath
val args = "java" :: globalBase :: "-jar" :: launcherJar :: "loadp" :: ( "<" + server.port) :: Nil
val io = BasicIO(log, false).withInput(_.close())
val p = Process(args, directory) run( io )
Spawn { p.exitValue(); server.close() }