aboutsummaryrefslogtreecommitdiffhomepage
path: root/lib/sisu/v6/rexml.rb
diff options
context:
space:
mode:
authorRalph Amissah <ralph@amissah.com>2014-07-22 21:30:56 -0400
committerRalph Amissah <ralph@amissah.com>2014-07-22 21:30:56 -0400
commit41796e30e4597c74e7e42c3144dbe5d4fb0687c5 (patch)
treed0615cafae5362873706f04595ee5b9333a758c3 /lib/sisu/v6/rexml.rb
parentv5 v6: version & changelog (& rakefile) (diff)
v5 v6: cosmetic code
Diffstat (limited to 'lib/sisu/v6/rexml.rb')
-rw-r--r--lib/sisu/v6/rexml.rb20
1 files changed, 17 insertions, 3 deletions
diff --git a/lib/sisu/v6/rexml.rb b/lib/sisu/v6/rexml.rb
index 63e70a42..7321ebf5 100644
--- a/lib/sisu/v6/rexml.rb
+++ b/lib/sisu/v6/rexml.rb
@@ -100,11 +100,20 @@ module SiSU_Rexml
xmlfile=IO.readlines(@fnap,'').join
begin
@xmldoc=REXML::Document.new xmlfile
- SiSU_Screen::Ansi.new(@md.opt.act[:color_state][:set],'invert','REXML',"XML document #{@fnap} loaded").colorize unless @md.opt.act[:quiet][:set]==:on
+ SiSU_Screen::Ansi.new(
+ @md.opt.act[:color_state][:set],
+ 'invert',
+ 'REXML',
+ "XML document #{@fnap} loaded"
+ ).colorize unless @md.opt.act[:quiet][:set]==:on
if (@opt.act[:verbose][:set]==:on \
|| @opt.act[:verbose_plus][:set]==:on)
@xmldoc.elements.each(@e_head) do |e|
- SiSU_Screen::Ansi.new(@md.opt.act[:color_state][:set],'brown',e).colorize unless @md.opt.act[:quiet][:set]==:on
+ SiSU_Screen::Ansi.new(
+ @md.opt.act[:color_state][:set],
+ 'brown',
+ e
+ ).colorize unless @md.opt.act[:quiet][:set]==:on
end
end
rescue REXML::ParseException
@@ -112,7 +121,12 @@ module SiSU_Rexml
end
end
else
- SiSU_Screen::Ansi.new(@md.opt.act[:color_state][:set],'fuchsia',"File Not Found #{xmlfile}",'requested XML processing skipped').colorize unless @md.opt.act[:quiet][:set]==:on
+ SiSU_Screen::Ansi.new(
+ @md.opt.act[:color_state][:set],
+ 'fuchsia',
+ "File Not Found #{xmlfile}",
+ 'requested XML processing skipped'
+ ).colorize unless @md.opt.act[:quiet][:set]==:on
exit
end
rescue