Last active
April 8, 2018 05:04
-
-
Save selfup/4a8eac6b4cf4b66842f2f24fe2fd5e42 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{:ok, ifs} = :inet.getif() | |
ips = | |
Enum.map(ifs, fn {ip, _b, _m} -> | |
Enum.join(Tuple.to_list(ip), ".") | |
end) | |
IO.inspect ips |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment