Skip to content

Instantly share code, notes, and snippets.

@Andrew8xx8
Created December 22, 2012 21:38
Show Gist options
  • Select an option

  • Save Andrew8xx8/4361324 to your computer and use it in GitHub Desktop.

Select an option

Save Andrew8xx8/4361324 to your computer and use it in GitHub Desktop.
lists:map(fun(Url) -> spawn(grabber, downloader, [self(), Url]) end, get_internal_links(Links, Host)),
=>
[ feed_grabber(Url) || Url <- get_internal_links(Links, Host) ]
links_by_body(Body) -> [Link]
body_by_url(Url) -> [Body]
download(Pid, Url) ->
Links = [ Link ||
Body <- body_by_url(Url),
Link <- links_by_body(Body) ],
Pid ! Links.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment