kevva / elm-bin

elm-platform bin-wrapper that makes it seamlessly available as a local dependency
MIT License
18 stars 5 forks source link

Is it possible to set environment variables? #22

Closed evancz closed 8 years ago

evancz commented 9 years ago

elm-reactor needs ELM_HOME, is that resolved? Can you point me to the relevant code if so?

We do different tricks with the mac and windows installers to do this. On mac we turn elm-reactor into a two part binary. The public one elm-reactor is just a thin wrapper that sets ELM_HOME to /usr/local/share/elm/ for the duration of the script and then calls elm-reactor-unwrapped which is the actual executable. This avoids any issues around "this shell sets variables like this, but that shell sets variables another way". Would that work here?

evancz commented 9 years ago

This has been messing things for a lot of folks, so as we were doing some recent work on Elm Reactor, I decided to bundle the static resources in the binary itself so that no one needs ELM_HOME anymore. That should be out with the next release of the platform.

The root problem here is still pretty bad. We hear about this on the mailing list and various repos pretty often.

rtfeldman commented 8 years ago

This is done now on the elm-platform npm installer, and can be closed.