diff options
author | Li Haoyi <haoyi.sg@gmail.com> | 2018-08-13 19:40:32 +0800 |
---|---|---|
committer | Li Haoyi <haoyi.sg@gmail.com> | 2018-08-13 19:40:32 +0800 |
commit | 916dcc20ee81d40ae264ecf102c47a3e2697a917 (patch) | |
tree | 722ef3ae171d3ca3caefb3127427ba376ad2ea50 /scalalib/src | |
parent | 1287d738d70ff6bf366accc78b45b643dbcf78ce (diff) | |
download | mill-916dcc20ee81d40ae264ecf102c47a3e2697a917.tar.gz mill-916dcc20ee81d40ae264ecf102c47a3e2697a917.tar.bz2 mill-916dcc20ee81d40ae264ecf102c47a3e2697a917.zip |
move forkWorkingDir from TestModule onto JavaModule so it can apply to run/runBackground
Diffstat (limited to 'scalalib/src')
-rw-r--r-- | scalalib/src/mill/scalalib/JavaModule.scala | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/scalalib/src/mill/scalalib/JavaModule.scala b/scalalib/src/mill/scalalib/JavaModule.scala index 0a26cf9e..83008d94 100644 --- a/scalalib/src/mill/scalalib/JavaModule.scala +++ b/scalalib/src/mill/scalalib/JavaModule.scala @@ -336,7 +336,7 @@ trait JavaModule extends mill.Module with TaskModule { outer => forkArgs(), forkEnv(), Seq(procId.toString, procTombstone.toString, token, mainClass) ++ args, - workingDir = ammonite.ops.pwd, + workingDir = forkWorkingDir, background = true )) catch { case e: InteractiveShelloutException => Result.Failure("subprocess failed") @@ -358,7 +358,7 @@ trait JavaModule extends mill.Module with TaskModule { outer => forkArgs(), forkEnv(), args, - workingDir = ammonite.ops.pwd + workingDir = forkWorkingDir )) catch { case e: InteractiveShelloutException => Result.Failure("subprocess failed") } @@ -371,14 +371,14 @@ trait JavaModule extends mill.Module with TaskModule { outer => def artifactId: T[String] = artifactName() def intellijModulePath: Path = millSourcePath + + def forkWorkingDir = ammonite.ops.pwd } trait TestModule extends JavaModule with TaskModule { override def defaultCommandName() = "test" def testFrameworks: T[Seq[String]] - def forkWorkingDir = ammonite.ops.pwd - def test(args: String*) = T.command{ val outputPath = T.ctx().dest/"out.json" |