[Pkg-puppet-devel] [SCM] Packaging of Facter for debian branch, upstream, updated. 3a39dd8353b6308cf49522990104cc63e55d7cda

Paul Nasrat pnasrat at googlemail.com
Fri Jan 29 17:22:29 UTC 2010


The following commit has been merged in the upstream branch:
commit 48aa1358d155f91e744011db6db2d41f3feed5bd
Author: Todd Zullinger <tmz at pobox.com>
Date:   Tue May 19 21:13:50 2009 -0400

    Fix operatingsystemrelease for CentOS < 5
    
    On older CentOS releases, a sed command is used to parse the release
    number from /etc/redhat-release.  However, the command lacked the proper
    amount of backslashes to escape the parenthesis.
    
    Signed-off-by: Paul Nasrat <pnasrat at googlemail.com>

diff --git a/lib/facter/operatingsystemrelease.rb b/lib/facter/operatingsystemrelease.rb
index d6e6e86..4393bfa 100644
--- a/lib/facter/operatingsystemrelease.rb
+++ b/lib/facter/operatingsystemrelease.rb
@@ -53,7 +53,7 @@ end
 Facter.add(:operatingsystemrelease) do
     confine :operatingsystem => %w{CentOS}
     setcode do
-        centos_release = Facter::Util::Resolution.exec("sed -r -e 's/CentOS release //' -e 's/ \((Branch|Final)\)//' /etc/redhat-release")
+        centos_release = Facter::Util::Resolution.exec("sed -r -e 's/CentOS release //' -e 's/ \\((Branch|Final)\\)//' /etc/redhat-release")
         if centos_release =~ /5/
             release = Facter::Util::Resolution.exec('rpm -q --qf \'%{VERSION}.%{RELEASE}\' centos-release | cut -d. -f1,2')
         else

-- 
Packaging of Facter for debian



More information about the Pkg-puppet-devel mailing list