Nithin Bekal Posts About

Shell History in Elixir (IEx) and Erlang

09 Jun 2016

Elixir does not support history in the iex shell across sessions. Although you can use the up/down arrows to access previously entered code, this history is lost once you close the iex session. This is one of the rare things that bothered me about the Elixir ecosystem.

Luckily, there is erlang-history, which adds shell history to Erlang shell. Elixir actually uses the Erlang shell behind the scenes, so this also works for IEx. To start using it, clone the github repo and run make install:

git clone
cd erlang-history
sudo make install

IEx is now working perfectly for me. Hopefully, something like this will be added to Erlang itself in the future, so that we can get this experience out of the box.

Nithin Bekal
Hi, I’m Nithin! This is my blog about programming. Ruby is my programming language of choice and the topic of most of my articles here, but I occasionally also write about Elixir, and sometimes about the books I read. I'm @nithinbekal on Twitter.