iex

interactive Elixir shell

TLDR

Start interactive Elixir
$ iex
Start with project
$ iex -S mix
Evaluate expression
$ iex -e "IO.puts(:hello)"
Connect to node
$ iex --remsh [node@host]
Start with name
$ iex --sname [mynode]
Load file
$ iex [script.exs]

SYNOPSIS

iex [options] [file]

DESCRIPTION

iex is the Interactive Elixir shell. It provides a REPL for evaluating Elixir expressions and exploring code.The shell supports tab completion, history, and documentation lookup. It integrates with Mix projects and remote nodes.

PARAMETERS

FILE

Script file to load.
-S SCRIPT
Run script (e.g., mix).
-e EXPR
Evaluate expression.
--remsh NODE
Remote shell to node.
--sname NAME
Short node name.
--name NAME
Full node name.
--help
Display help information.

INSTALL

sudo apt install elixir
sudo dnf install elixir
sudo pacman -S elixir
sudo apk add elixir
sudo zypper install elixir
brew install elixir

CAVEATS

Requires Elixir/Erlang. Node features need setup. Mix integration common.

HISTORY

iex is part of Elixir, created by José Valim as a functional language on the Erlang VM.

SEE ALSO

elixir(1), mix(1), erl(1)