Module: Facter::Util::Macaddress

Defined in:
lib/facter/util/macaddress.rb

Overview

A module to gather macaddress facts

Defined Under Namespace

Modules: Darwin, Windows

Class Method Summary collapse

Class Method Details

.standardize(macaddress) ⇒ Object



5
6
7
8
# File 'lib/facter/util/macaddress.rb', line 5

def self.standardize(macaddress)
  return nil unless macaddress
  macaddress.split(":").map{|x| "0#{x}"[-2..-1]}.join(":")
end