aboutsummaryrefslogtreecommitdiffhomepage
path: root/lib/sisu/v3dv/composite.rb
diff options
context:
space:
mode:
authorRalph Amissah <ralph@amissah.com>2012-01-23 21:52:37 -0500
committerRalph Amissah <ralph@amissah.com>2012-01-23 21:52:37 -0500
commitdc5c01b1033cfc9e09fd4fc29666e826e67cd7bb (patch)
treee53a389c4f669d79b5b82ce6fd1853da6b25f85d /lib/sisu/v3dv/composite.rb
parentdebian/changelog (3.1.11-1) (diff)
parentv3dv: replace use of most ruby exclamation (!) method actions (diff)
Merge commit 'sisu_3.1.12' into debian/sid
Diffstat (limited to 'lib/sisu/v3dv/composite.rb')
-rw-r--r--lib/sisu/v3dv/composite.rb19
1 files changed, 8 insertions, 11 deletions
diff --git a/lib/sisu/v3dv/composite.rb b/lib/sisu/v3dv/composite.rb
index abfba7a2..21adb030 100644
--- a/lib/sisu/v3dv/composite.rb
+++ b/lib/sisu/v3dv/composite.rb
@@ -161,11 +161,11 @@ module SiSU_Assemble
end
if not @code_flag \
and i !~/^%+\s/
- i.gsub!(/^([123]|:?[ABC])~\? /,'% [conditional heading:] \1~ ') #off conditional heading (consider syntax)
+ i=i.gsub(/^([123]|:?[ABC])~\? /,'% [conditional heading:] \1~ ') #off conditional heading (consider syntax)
if i =~/^@\S+?:/
- i.gsub!(/\n/m,"\n% ")
- i.gsub!(/\n%\s+$/m,'')
- i.gsub!(/^@\S+?:/m,"\n% [imported header:] ") #off imported headers
+ i=i.gsub(/\n/m,"\n% ").
+ gsub(/\n%\s+$/m,'').
+ gsub(/^@\S+?:/m,"\n% [imported header:] ") #off imported headers
end
end
file[:prepared] << i
@@ -176,8 +176,7 @@ module SiSU_Assemble
end
file[:prepared] << "\n% end import" << "\n\n"
if file[:images].length > 0
- file[:images].flatten!
- file[:images].uniq!
+ file[:images]=file[:images].flatten.uniq
file[:images].delete_if {|x| x =~/https?:\/\// }
end
file
@@ -218,15 +217,13 @@ module SiSU_Assemble
end
else tuned_file << para
end
- tuned_file.flatten!
- tuned_file.compact!
+ tuned_file=tuned_file.flatten.compact
end
if @@imager.length >0
@@imager.each do |d,i|
- i.flatten!
- i.uniq!
+ i=i.flatten.uniq
image_info=d + i
- download_images(mage_info.flatten)
+ download_images(image_info.flatten)
end
end
tuned_file