if File.exists?("/etc/facts.txt")
File.open("/etc/facts.txt").each do |line|
if line =~ /^(.+)=(.+)$/
var = $1
val = $2

Facter.add(var) do
setcode { val }
end
end
end
end