Hello fellow alchemists, There are Erlang hex packages which depend on env variables either in Makefiles or in rebar.config.script. A very popular example package is elixometer <https://github.com/pinterest/elixometer>, which depends on exometer <https://github.com/Feuerlabs/exometer>, which requires setting the EXOMETER_PACKAGES variable to configure its dependencies (see: https://github.com/Feuerlabs/exometer#dependency-management).
For both Mix.Tasks.Deps.Compile.do_rebar/2 and Mix.Tasks.Deps. Compile.do_rebar3/2 the env for Mix.Shell.cmd/2 cannot be altered from within mix.exs (see: https://github.com/elixir-lang/elixir/blob/master/lib/mix/lib/mix/tasks/deps.compile.ex#L162 ). I propose allowing a dependency declaration like the following in mix.exs: def deps do {:exometer, "~> 1.2.1", env: [{"EXOMETER_PACKAGES", "(basic), +afunix"}]} end That env can be passed to do_compile/2, do_make/2, do_rebar/2, do_rebar3/2. I have intent to prepare a PR for this change. Please let me know your thought about this, Dimitris -- You received this message because you are subscribed to the Google Groups "elixir-lang-core" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/elixir-lang-core/8ef2ba77-8752-4fb2-9005-9b51ef434258%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
