via asdf in my zsh shell. Enabled the versions locally and globally.
When I list them via ‘asdf list elixir’ or ‘asdf list erlang’ the correct versions are listed but not usable.
→ it keeps on showing: zsh: command not found: iex
I had the latest version of Elixir installed by homebrew before, which worked flawlessly.
Before the installation via asdf I uninstalled the brew installed version.
It keeps on not working after updating my OS(Monterey 12.2.1), updating brew, cleaning up brew, copying suggested lines to zsh, restarting my computer, etc.
Does anyone runs into the same issue or knows a workaround? Am I overlooking something?
(base) ➜ ~ asdf which elixir
HOME/.asdf/installs/elixir/1.11.2/bin/elixir
(base) ➜ ~ HOME/.asdf/installs/elixir/1.11.2/bin/elixir --version HOME/.asdf/installs/elixir/1.11.2/bin/elixir: line 230: exec: erl: not found
I get the error above.
So I tried fixing it with setting export erl=HOME/.asdf/installs/erlang/23.3.4/bin/erl
in ~/.zshenv
However
(base) ➜~ echo $erl
shows me
HOME/.asdf/installs/erlang/23.3.4/bin/erl
but just typing
(base) ➜~ erl
zsh: command not found: erl
Seems to me this is a zsh issue or I’m making a mistake?
I tried doing this and it worked fine, but after restarting my laptop asdf is gone. I tried this twice ad asdf gets uninstalled both the times after restarting my laptop, what should I do?
Did you put the export command right into your terminal or did you put it in your shell configuration file?(something like ~/.bashrc or ~/.zshrc)
The first solution will only work for your current terminal session, whereas the latter solution will run the export command at each terminal session startup.