2016-11-12 57 views
2

Elixir初學者在這裏。我試圖從IEXElixir未定義函數

腳本運行一個Hello World仙丹腳本是一個基本的Hello World示例

IO.puts "Hello World!" 

我跑從IEX

iex(1)> elixir hello.exs 

以下命令,得到這個錯誤:

** (CompileError) iex:1: undefined function elixir/1 

不知道爲什麼我得到一個錯誤,任何幫助,將不勝感激。由於

+4

您應該從shell中運行'靈藥hello.exs',內部沒有'iex'。 – Dogbert

回答

7

正是這樣的答案不是埋在註釋:

You should run elixir hello.exs from the shell, not inside iex