components/ruby/facter/patches/facter-03-FACT-658.patch
changeset 5860 afd31ba91ee9
parent 2068 4e371f01e40f
equal deleted inserted replaced
5859:98bc99958997 5860:afd31ba91ee9
     1 Patch for FACT-658 facter doesn't parse gnu uptime output
     1 Patch for FACT-658 facter doesn't parse gnu uptime output
     2 Upstream bug: https://tickets.puppetlabs.com/browse/FACT-658
     2 Upstream bug: https://tickets.puppetlabs.com/browse/FACT-658
     3 --- facter-2.1.0/lib/facter/util/uptime.rb.orig	2014-08-15 10:19:59.183717181 -0600
     3 
     4 +++ facter-2.1.0/lib/facter/util/uptime.rb	2014-08-15 10:44:49.611645182 -0600
     4 --- facter-2.4.6/lib/facter/util/uptime.rb.orig	2016-04-19 15:19:02.924027657 -0700
     5 @@ -76,6 +76,14 @@
     5 +++ facter-2.4.6/lib/facter/util/uptime.rb	2016-04-19 15:20:09.128836906 -0700
       
     6 @@ -1,3 +1,7 @@
       
     7 +#######################################################################
       
     8 +# Oracle has modified the originally distributed contents of this file.
       
     9 +#######################################################################
       
    10 +
       
    11  require 'time'
       
    12  
       
    13  # A module to gather uptime facts
       
    14 @@ -78,6 +82,14 @@
     6    end
    15    end
     7  
    16  
     8    def self.uptime_executable_cmd
    17    def self.uptime_executable_cmd
     9 -    "uptime"
    18 -    "uptime"
    10 +    if Facter.value(:kernel) == 'SunOS'
    19 +    if Facter.value(:kernel) == 'SunOS'