Every story and comment from the Hacker News API, in a layout borrowed from 2001.
A comment on Playing with Go: Embarrassingly Parallel Scripts. Parent comment
https://gist.github.com/bb01a85404e6b445dcb3#file_resolve_do...
% -*- erlang -*- %%! -smp enable worker(Hostname) -> {ok, IP} = inet:getaddr(Hostname, inet), io:format( "~s => ~s~n", [ip_to_string(IP)] ). ip_to_string({N1,N2,N3,N4}) -> io_lib:format( "~w.~w.~w.~w", [N1,N2,N3,N4] ). main([DomainFile]) -> {ok, Bin} = file:read_file(DomainFile), String = binary_to_list(Bin), Domains = string:tokens(String, "\n"), plists:foreach( fun(Domain) -> worker(Domain) end, Domains ).
There are no comments on this comment yet.
https://gist.github.com/bb01a85404e6b445dcb3#file_resolve_do...
This uses https://github.com/eveel/plists/