Skip to content

Instantly share code, notes, and snippets.

View crawler.ex
def crawl(config) do
config
|> Enum.map(&Task.Supervisor.async(TaskModule, fn() -> check(&1) end))
|> Enum.map(&Task.await(&1))
end
@bcat-eu
bcat-eu / time.ex
Last active Oct 10, 2016
Current time helper module for Elixir
View time.ex
defmodule Util.Time do
@moduledoc """
Time helper functions.
"""
@doc """
Get current time as string using Erlangs calendar module.
"""
@spec now_to_string() :: String.t
def now_to_string() do