3 ms·
Are you sure? I would be astonished if Erlang didn't have a way to export environment variables for child processes. In a language that provides nothing beyond
by kazinator 3y ago
Are you sure? I would be astonished if Erlang didn't have a way to export environment variables for child processes.
In a language that provides nothing beyond a function that lets you run system commands, you can control the child's environment via the env utility:
system("env FOO=bar command arg ...");
- pmarreck 3y agoThe context here is that I may want to run an Elixir script from a Bash command line which results in some environment variables being changed. I don't think that's possible unless that script itself sends that env command to STDOUT, and I then capture it and eval it on the Bash side. Which seems... inelegant.