diff options
author | Olivier Melois <olivierm@cakesolutions.net> | 2018-03-29 21:03:27 +0100 |
---|---|---|
committer | Olivier Melois <olivierm@cakesolutions.net> | 2018-03-29 21:12:55 +0100 |
commit | a96754b75c1fbf1959aeac59040588211f5327c2 (patch) | |
tree | 75e2d6c69c2e28d4500505da002ea387f2771027 /main/src/mill/main/MainRunner.scala | |
parent | 41ca6c22894e863f5042cd8f49f5c3c6d52acc23 (diff) | |
download | mill-a96754b75c1fbf1959aeac59040588211f5327c2.tar.gz mill-a96754b75c1fbf1959aeac59040588211f5327c2.tar.bz2 mill-a96754b75c1fbf1959aeac59040588211f5327c2.zip |
Adds envVars propagation client -> server
Since Mill now executes in a long-lived JVM, the builds do not have a
chance to use environment variables as inputs. This propagates the
environment variables from the client all the way down to the context
available to the tasks as a `Map[String, String]` so that they can be
used as inputs should the user choose to do so.
https://github.com/lihaoyi/mill/issues/257
Diffstat (limited to 'main/src/mill/main/MainRunner.scala')
-rw-r--r-- | main/src/mill/main/MainRunner.scala | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/main/src/mill/main/MainRunner.scala b/main/src/mill/main/MainRunner.scala index efebd5a5..fed664fd 100644 --- a/main/src/mill/main/MainRunner.scala +++ b/main/src/mill/main/MainRunner.scala @@ -20,7 +20,8 @@ class MainRunner(val config: ammonite.main.Cli.Config, outprintStream: PrintStream, errPrintStream: PrintStream, stdIn: InputStream, - stateCache0: Option[Evaluator.State] = None) + stateCache0: Option[Evaluator.State] = None, + env : Map[String, String]) extends ammonite.MainRunner( config, outprintStream, errPrintStream, stdIn, outprintStream, errPrintStream @@ -75,7 +76,8 @@ class MainRunner(val config: ammonite.main.Cli.Config, errPrintStream, errPrintStream, stdIn - ) + ), + env ) result match{ |