Erlang Homepage

Hi I have a command that launches an Erlang node (using the run_erl program) and then I connect to it using the to_erl program. After connecting to node, I issue the following command to get the home directory.

init:get_argument(home). 

And it returns "/" as the home directory, which, as I know, is definitely invalid. What is the reason for this?

+4
source share
1 answer

I don’t know how you configure, so it’s hard to parse, but calling init: get_argument (home) will return the value of the HOME environment variable (in any unix form and you can check it by calling echo $ START).

+4
source

Source: https://habr.com/ru/post/1483590/


All Articles