On Jul 3, 2007, at 9:52 AM, Robert Dober wrote:

> On 7/3/07, ara.t.howard <ara.t.howard / gmail.com> wrote:
> <snip>
>>
>> thanks!
>>
>> -a
>> --
> Nope on Linux
>

huh.  does for me!?

> def mac_address
>      return @mac_address if defined? @mac_address
>      re =  %r<(?:hwaddr|:)\s+((?:[0-9a-f]{1,2}[-:]){5}[0-9a-f]{1,2}) 
> \s*$>i
>      lines =
>        begin
>          IO.popen('ifconfig'){|fd| fd.readlines}
>        rescue
>          IO.popen('ipconfig /all'){|fd| fd.readlines}
>        end
>      candidates = lines.map{|l| re.match( l )[1] rescue nil }.compact
>      @mac_address = candidates.first
>    end
>
> but not tested on Windows
> HTH
> Robert
> -- 

can someone give this version a whirl on windows?

-a
--
we can deny everything, except that we have the possibility of being  
better. simply reflect on that.
h.h. the 14th dalai lama