summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorPaul Nasrat <pnasrat@googlemail.com>2008-07-17 14:54:52 +0100
committerPaul Nasrat <pnasrat@googlemail.com>2008-07-17 14:54:52 +0100
commitbb235e349774d29e1a1a8766125f241ddb598f68 (patch)
tree9a4608711dadaef421ede4b1c45b0f7a81ff0e89 /lib
parent3f180b309b1187d6f5cdb24715b2807c0406ef4d (diff)
downloadfacter-bb235e349774d29e1a1a8766125f241ddb598f68.tar.gz
facter-bb235e349774d29e1a1a8766125f241ddb598f68.tar.xz
facter-bb235e349774d29e1a1a8766125f241ddb598f68.zip
Use rbconfig to detect host cpu
Diffstat (limited to 'lib')
-rw-r--r--lib/facter/hardwaremodel.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/facter/hardwaremodel.rb b/lib/facter/hardwaremodel.rb
index 92f8257..6201bdd 100644
--- a/lib/facter/hardwaremodel.rb
+++ b/lib/facter/hardwaremodel.rb
@@ -11,3 +11,11 @@ Facter.add(:hardwaremodel) do
end
end
end
+
+Facter.add(:hardwaremodel) do
+ confine :operatingsystem => :windows
+ setcode do
+ require 'rbconfig'
+ Config::CONFIG['host_cpu']
+ end
+end