diff options
| author | Dominic Cleal <dcleal@redhat.com> | 2010-11-15 22:49:46 +0000 |
|---|---|---|
| committer | Dominic Cleal <dcleal@redhat.com> | 2010-11-15 22:49:46 +0000 |
| commit | 69a3451cb89c819291721f810b58f3ccf08b4cc5 (patch) | |
| tree | 84dd532f0881376ff8cbd803ffb03b62c56ee437 /lib | |
| parent | 919638ec97568536f90e23b9c63a35a134e948a4 (diff) | |
| download | puppet-69a3451cb89c819291721f810b58f3ccf08b4cc5.tar.gz puppet-69a3451cb89c819291721f810b58f3ccf08b4cc5.tar.xz puppet-69a3451cb89c819291721f810b58f3ccf08b4cc5.zip | |
Adding patch from Rudy Gevaert to fix not installed detection
Diffstat (limited to 'lib')
| -rwxr-xr-x | lib/puppet/provider/package/pkgutil.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/puppet/provider/package/pkgutil.rb b/lib/puppet/provider/package/pkgutil.rb index b8ad54892..05d189d0b 100755 --- a/lib/puppet/provider/package/pkgutil.rb +++ b/lib/puppet/provider/package/pkgutil.rb @@ -67,15 +67,15 @@ Puppet::Type.type(:package).provide :pkgutil, :parent => :sun, :source => :sun d # Split the different lines into hashes. def self.blastsplit(line) - if line =~ /\s*(\S+)\s+((\[Not installed\])|(\S+))\s+(\S+)/ + if line =~ /\s*(\S+)\s+(\S+)\s+(.*)/ hash = {} hash[:name] = $1 - hash[:ensure] = if $2 == "[Not installed]" + hash[:ensure] = if $2 == "notinst" :absent else $2 end - hash[:avail] = $5 + hash[:avail] = $3 if hash[:avail] == "SAME" hash[:avail] = hash[:ensure] |
