我不斷收到這樣的警告,當我運行IEX使用仙丹模式,IEX退出Emacs: Warning: could not run smart terminal, falling back to dumb one
我認爲,這只是意味着我不明白tab完成,這我很好。但是如果在Emacs中使用elixir模式,我想要一個智能終端。
我試圖在Elixir中使用Google Maps地理編碼API,儘管我對該語言有點新,所以使用嵌套數據結構工作正在避開我。 我使用HTTPotion從地理編碼端點獲取JSON,並使用JSEX將其解析爲Elixir數據結構(一系列嵌套列表和元組)。 defmodule Geocode do
def fetch do
HTTPotion.start
result = HT
如果我有一個mix.exs文件像怎麼辦: defmodule Mix.Tasks.My_task do
use Mix.Task
@shortdoc "Perform my task"
def run(_) do
IO.puts "Working"
end
end
defmodule ElixirKoans.Mixfile do
我想用Elixir來映射陣列(n個陣列)的每個正方形。 使用Ruby,這可能是與此一堆代碼來完成: class Object
def deep_map(&block)
block.call(self)
end
end
class Array
def deep_map(&block)
map {|e| e.deep_map(&block) }