programming:elixir:setup
Setup
ASDF
$ git clone https://github.com/asdf-vm/asdf.git ~/.asdf --branch v0.12.0
Then, depending on what shell you use, load asdf at startup.
Erlang
$ asdf plugin add erlang https://github.com/asdf-vm/asdf-erlang.git
Then install the latest version. The command bellow shows all available Erlang versions:
$ asdf list all erlang
Before compiling Erlang, you have to install build-time dependencies.
Also, since the Java interface is not used, you can disable it.
$ export KERL_BUILD_DOCS=yes $ export KERL_CONFIGURE_OPTIONS="--disable-debug --without-javac" $ asdf install erlang <VERSION>
Finally, set Erlang's version:
$ asdf global erlang <VERSION>
Elixir
$ asdf plugin-add elixir https://github.com/asdf-vm/asdf-elixir.git
Then install the latest version. The command bellow shows all available Elixir's versions:
$ asdf list all elixir
The Elixir team offers pre-compiled binaries, thus you do not need to compile the language.
$ asdf install elixir <VERSION>
Finally, set Elixir's version:
$ asdf global elixir <VERSION>
If you want to navigate through iex's command history, add the following to the startup file of your shell (.bashrc or .zshrc)
export ERL_AFLAGS="-kernel shell_history enabled"
programming/elixir/setup.txt · Last modified: 2023/06/27 09:52 by maferreira