Fork me on GitHub
#tools-build
<
2022-06-09
>
Joshua Suskalo17:06:49

Is there an established way to set the environment variables in a java-command call?

Joshua Suskalo17:06:31

I'd like to be able to set test.chuck's TEST_CHECK_FACTOR to a value when running the tests from my build alias.

Alex Miller (Clojure team)17:06:51

no, as that's not part of a java command. with process , you can use :env to set env vars

Joshua Suskalo17:06:03

alright, thanks.

Alex Miller (Clojure team)17:06:22

so you can merge that into the result of java-command, then pass to process

Joshua Suskalo17:06:17

I'm using sean's build-clj run-tests var so I was hoping to be able to just pass something. Since that wasn't quite possible what I've opted for is to just pass a -e to clojure.main to evaluate a form that will set the factor to the value I want.