Split patching message into downloading and patching

This commit is contained in:
Adam Vandenberg 2010-05-11 08:34:29 -07:00
parent 48bfd8a585
commit 11449bfd67

View File

@ -378,7 +378,6 @@ private
def patch def patch
return if patches.nil? return if patches.nil?
ohai "Patching"
if not patches.kind_of? Hash if not patches.kind_of? Hash
# We assume -p1 # We assume -p1
patch_defns = { :p1 => patches } patch_defns = { :p1 => patches }
@ -422,9 +421,11 @@ private
return if patch_list.empty? return if patch_list.empty?
ohai "Downloading patches"
# downloading all at once is much more efficient, espeically for FTP # downloading all at once is much more efficient, espeically for FTP
curl *(patch_list.collect{|p| p[:curl_args]}.select{|p| p}.flatten) curl *(patch_list.collect{|p| p[:curl_args]}.select{|p| p}.flatten)
ohai "Patching"
patch_list.each do |p| patch_list.each do |p|
case p[:compression] case p[:compression]
when :gzip then safe_system "/usr/bin/gunzip", p[:filename]+'.gz' when :gzip then safe_system "/usr/bin/gunzip", p[:filename]+'.gz'