Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/auser/macmap

A single method to provide a map of network interfaces to their corresponding ip addresses from ifconfig
https://github.com/auser/macmap

Last synced: 15 days ago
JSON representation

A single method to provide a map of network interfaces to their corresponding ip addresses from ifconfig

Awesome Lists containing this project

README

        

= macmap

Ever wanted to map your interface to an ip?

If you haven't, why not?

Alas, Macmap is here to help!

Usage is easy:

Macmap.map_iface_to_ip %x{ifconfig -a}

Or

require "rubygems"
require "popen3"

Open3.popen3('ifconfig -a') { |stdin, stdout, stderr| Macmap.map_iface_to_ip(stdout) }

Try it! It's fun

== Copyright

Copyright (c) 2009 Ari Lerner. See LICENSE for details.