From 8643893b38be6b3c0cd00c1d2f741339299f6050 Mon Sep 17 00:00:00 2001 From: Ralph Amissah Date: Mon, 30 Jul 2007 13:35:49 +0100 Subject: processed number added for urls and remote placement --- lib/sisu/v0/hub.rb | 29 ++++++++++++++++------------- 1 file changed, 16 insertions(+), 13 deletions(-) (limited to 'lib') diff --git a/lib/sisu/v0/hub.rb b/lib/sisu/v0/hub.rb index 125a0500..9f4be964 100644 --- a/lib/sisu/v0/hub.rb +++ b/lib/sisu/v0/hub.rb @@ -132,11 +132,11 @@ module SiSU @opt.fns=fns if @req !~/(?:urls|remote_put)$/ if FileTest.file?(@opt.fns) - case @opt.fns - when /\.(?:[_-]?sst|ssm)$/ + case @opt.fns + when /\.(?:[_-]?sst|ssm)$/ case @req when /^dal$/ - if fns =~ /\.ssm$/; require "#{SiSU_lib}/composite" #pre-processing + if fns =~ /\.ssm$/; require "#{SiSU_lib}/composite" #pre-processing SiSU_Assemble::Composite.new(@opt).read @opt.fns=fns.gsub(/\.ssm$/,'._sst') end @@ -163,12 +163,12 @@ module SiSU when /^zap$/; SiSU_Zap::Source.new(@opt).read # -Z when /^dbi$/; SiSU_DBI::SiSU_SQL.new(@opt).connect # -D -d end - @n_do=@n_do+1 + @n_do=@n_do+1 tell=SiSU_Screen::Ansi.new(@opt.cmd,@n_do,"#{@req.upcase} processed") tell.files_processed unless @opt.cmd =~/q/ ObjectSpace.garbage_collect - else #print "not processed --> ", fns, "\n" - end + else #print "not processed --> ", fns, "\n" + end else Operations.new(@opt).not_found end elsif FileTest.file?(put) @@ -181,6 +181,9 @@ module SiSU else #SiSU_Remote::Put.new(put,@opt.cmd).scp end end + @n_do=@n_do+1 + tell=SiSU_Screen::Ansi.new(@opt.cmd,@n_do,"#{@req.upcase} processed") + tell.files_processed unless @opt.cmd =~/q/ else Operations.new(@opt).not_found end end @@ -374,7 +377,7 @@ p "here #{__FILE__} #{__LINE__}" if @opt =~/M/ @get_s,@get_p=[],[] re_s=/(http:\/\/\S+?\.sst)/ re_p=/(http:\/\/\S+?(?:\/sisupod(?:\.zip)?|\.ssp))/ - @opt.files.each do |fns| + @opt.files.each do |fns| if fns =~re_s @get_s << re_s.match(fns)[1] if re_s end @@ -477,16 +480,16 @@ p "here #{__FILE__} #{__LINE__}" if @opt =~/M/ end if @opt.cmd =~/t/ #% -t termsheet/standard form SiSU_Help::Help.new('termsheet').help_request - @opt.files.each do |fns| + @opt.files.each do |fns| if FileTest.file?(fns) @opt.fns=fns - case @opt.fns - when /\.(termsheet.rb)$/; Operations.new(@opt).termsheet - else #print "not processed --> ", fns, "\n" - end + case @opt.fns + when /\.(termsheet.rb)$/; Operations.new(@opt).termsheet + else #print "not processed --> ", fns, "\n" + end else Operations.new(@opt).not_found end - end + end Operations.new.counter end if @opt.cmd =~/T/; op('xml_scaffold','XML scaffold') #% -T temporary tests -- cgit v1.2.3