8

I am trying to install elixir in ubuntu... I had followed this instructions.

Everthing seems fine, but when I try to execute the mix comand, system asnwered me this:

bash: /usr/bin/mix: No such file or directory

Thanks you.

Eloy Fernández Franco
  • 1,350
  • 1
  • 24
  • 47

4 Answers4

4

Just ran into the same problem. The guide you linked installs mix to /usr/local/bin/mix instead of /usr/local/mix. I created a symlink /usr/bin/mix but expanding $PATH is probably a better way to fix this.

~$ mix
-bash: /usr/bin/mix: No such file or directory
~$ which mix
/usr/local/bin/mix
~$ sudo ln -s /usr/local/bin/mix /usr/bin/mix
~$ mix
** (Mix) Could not find a Mix.Project, please ensure a mix.exs file is available
1

in my case i have installed elixir using sudo so when you try to call it without sudo you'll get this error.

Badr Bellaj
  • 11,560
  • 2
  • 43
  • 44
0

Also ran into this. In my case it stemmed from having CDPATH set.

Unsetting it for the session with unset CDPATH and retrying did the trick.

jmromer
  • 2,212
  • 1
  • 12
  • 24
0

In my case I reinstalled Erlang via sudo apt-get install erlang-base and during installation, Elixir got removed altogether.

Fixed that by running sudo apt-get install elixir.

All repositories were preset for me already.

denis.peplin
  • 9,585
  • 3
  • 48
  • 55