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 --- CHANGELOG | 3 +++ lib/sisu/v0/hub.rb | 29 ++++++++++++++++------------- 2 files changed, 19 insertions(+), 13 deletions(-) diff --git a/CHANGELOG b/CHANGELOG index 57dde75f..2ad0ae76 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -20,6 +20,9 @@ http://www.jus.uio.no/sisu/pkg/src/sisu_0.55.7.orig.tar.gz constructed in param, it is necessary to rebuild database (re-create and re-populate) for this to take effect [sisu -Dv --recreate] + * added processed count info for output urls and remote placement (to + existing counts) + %% sisu_0.55.6.orig.tar.gz (2007-07-28:30/6) http://www.jus.uio.no/sisu/pkg/src/sisu_0.55.6.orig.tar.gz 69368f8eb4da28d07f3a1ee1ea5b89f3 1271022 sisu_0.55.6.orig.tar.gz 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 From f17c8b940681250dacd0154033525658ad5c0a08 Mon Sep 17 00:00:00 2001 From: Ralph Amissah Date: Mon, 30 Jul 2007 13:43:37 +0100 Subject: replace unintended tabs with spaces --- CHANGELOG | 2 ++ lib/sisu/v0/hub.rb | 4 ++-- lib/sisu/v0/odf.rb | 2 +- lib/sisu/v0/param.rb | 2 +- lib/sisu/v0/plaintext.rb | 2 +- lib/sisu/v0/sst_do_inline_footnotes.rb | 2 +- lib/sisu/v0/sst_to_s_xml_dom.rb | 2 +- lib/sisu/v0/sst_to_s_xml_node.rb | 2 +- lib/sisu/v0/sst_to_s_xml_sax.rb | 2 +- lib/sisu/v0/sysenv.rb | 12 ++++++------ lib/sisu/v0/texinfo.rb | 2 +- lib/sisu/v0/wikispeak.rb | 2 +- lib/sisu/v0/xhtml.rb | 2 +- lib/sisu/v0/xml.rb | 2 +- lib/sisu/v0/xml_dom.rb | 2 +- 15 files changed, 22 insertions(+), 20 deletions(-) diff --git a/CHANGELOG b/CHANGELOG index 2ad0ae76..da06b83e 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -23,6 +23,8 @@ http://www.jus.uio.no/sisu/pkg/src/sisu_0.55.7.orig.tar.gz * added processed count info for output urls and remote placement (to existing counts) + * some unintended tabs replaced with spaces + %% sisu_0.55.6.orig.tar.gz (2007-07-28:30/6) http://www.jus.uio.no/sisu/pkg/src/sisu_0.55.6.orig.tar.gz 69368f8eb4da28d07f3a1ee1ea5b89f3 1271022 sisu_0.55.6.orig.tar.gz diff --git a/lib/sisu/v0/hub.rb b/lib/sisu/v0/hub.rb index 9f4be964..d1396331 100644 --- a/lib/sisu/v0/hub.rb +++ b/lib/sisu/v0/hub.rb @@ -233,7 +233,7 @@ p "here #{__FILE__} #{__LINE__}" if @opt =~/M/ end def termsheet # -t system("sisu_termsheet #{@opt.cmd} #{@opt.fns}\n") - @@n_do=@@n_do+1 + @@n_do=@@n_do+1 tell=SiSU_Screen::Ansi.new(@opt.cmd,@@n_do,'Termsheet(s) processed') tell.term_sheet_title unless @opt.cmd =~/q/ end @@ -242,7 +242,7 @@ p "here #{__FILE__} #{__LINE__}" if @opt =~/M/ prt=if prt !~/\d+/; 'webrick default (sysenv)' else "webrick port set to #{prt}" end - puts %{#{@cX.blue}<<#{@cX.off}#{@cX.green}Start Webrick web server on port: #{prt}#{@cX.off}#{@cX.blue}>> #{@cX.off*2} } + puts %{#{@cX.blue}<<#{@cX.off}#{@cX.green}Start Webrick web server on port: #{prt}#{@cX.off}#{@cX.blue}>> #{@cX.off*2} } system("sisu_webrick #{port}&\n") end def semantics diff --git a/lib/sisu/v0/odf.rb b/lib/sisu/v0/odf.rb index 6025dfb2..381e23d4 100644 --- a/lib/sisu/v0/odf.rb +++ b/lib/sisu/v0/odf.rb @@ -507,7 +507,7 @@ module SiSU_ODF if para =~/^0~(\S+)\s+(.+?)\Z/m # for headers d_meta=SiSU_text_utils::Header_scan.new(@md,para).meta if d_meta; odf_metadata(d_meta) - end + end end @rcdc=true if @rcdc==false and (para =~/~metadata/ or para =~/1~\s+Document Information/) if para !~/(^0~||)/ diff --git a/lib/sisu/v0/param.rb b/lib/sisu/v0/param.rb index 2264c48a..211516ad 100644 --- a/lib/sisu/v0/param.rb +++ b/lib/sisu/v0/param.rb @@ -240,7 +240,7 @@ module SiSU_Param if para !~/^\%+\s/ and para =~/|)/ if para =~@regx #/.+?<~\d+;\w\d+;\w\d+>.*/ #watch change diff --git a/lib/sisu/v0/sst_do_inline_footnotes.rb b/lib/sisu/v0/sst_do_inline_footnotes.rb index cf94300b..3a6282c4 100644 --- a/lib/sisu/v0/sst_do_inline_footnotes.rb +++ b/lib/sisu/v0/sst_do_inline_footnotes.rb @@ -272,7 +272,7 @@ module SiSU_Convert_footnotes para.gsub!(/^7~/,'4~') para.gsub!(/^8~/,'5~') para.gsub!(/^9~/,'6~') - end + end if para =~/<:insert\d+!?>/ and para !~/^%\s+/ @skin.select #require "#{@md.doc_skin}" #FIX now diff --git a/lib/sisu/v0/sst_to_s_xml_dom.rb b/lib/sisu/v0/sst_to_s_xml_dom.rb index 4d5bd0fe..84f72037 100644 --- a/lib/sisu/v0/sst_to_s_xml_dom.rb +++ b/lib/sisu/v0/sst_to_s_xml_dom.rb @@ -354,7 +354,7 @@ WOK if para =~/\A(?:@|0~)(\S+?):?\s+(.+?)\Z/m d_meta=SiSU_text_utils::Header_scan.new(@md,para).meta if d_meta; xml_head(d_meta) - end + end end @rcdc=true if @rcdc==false and (para =~/~metadata/ or para =~/^1~\s+Document Information/) if para !~/(^0~|^@\S+?:||)/ diff --git a/lib/sisu/v0/sst_to_s_xml_node.rb b/lib/sisu/v0/sst_to_s_xml_node.rb index 8b9c1f12..8ed1b51b 100644 --- a/lib/sisu/v0/sst_to_s_xml_node.rb +++ b/lib/sisu/v0/sst_to_s_xml_node.rb @@ -411,7 +411,7 @@ WOK if para =~/\A(?:@|0~)(\S+?):?\s+(.+?)\Z/m # for headers d_meta=SiSU_text_utils::Header_scan.new(@md,para).meta if d_meta; xml_head(d_meta) - end + end end end end diff --git a/lib/sisu/v0/sst_to_s_xml_sax.rb b/lib/sisu/v0/sst_to_s_xml_sax.rb index 42e13e08..5a232455 100644 --- a/lib/sisu/v0/sst_to_s_xml_sax.rb +++ b/lib/sisu/v0/sst_to_s_xml_sax.rb @@ -263,7 +263,7 @@ WOK if para =~/\A(?:@|0~)(\S+?):?\s+(.+?)\Z/m # for headers d_meta=SiSU_text_utils::Header_scan.new(@md,para).meta if d_meta; xml_head(d_meta) - end + end end @rcdc=true if @rcdc==false and (para =~/~metadata/ or para =~/^1~\s+Document Information/) if para !~/(^0~|^@\S+?:|^\s*$||)/ diff --git a/lib/sisu/v0/sysenv.rb b/lib/sisu/v0/sysenv.rb index 91e03459..10ec5e33 100644 --- a/lib/sisu/v0/sysenv.rb +++ b/lib/sisu/v0/sysenv.rb @@ -1328,13 +1328,13 @@ module SiSU_Env "#{http}#{@rc['webserv_cgi']['host']}:#{webserv_port_cgi}/#@stub_pwd" else "#{http}#{@rc['webserv_cgi']['host']}/#@stub_pwd" end - else + else http=webserv_host_base=~/http:\/\// ? '' : 'http://' if webserv_port_cgi "#{http}#{webserv_host_base}:#{webserv_port_cgi}/#@stub_pwd" else "#{http}#{webserv_host_base}/#@stub_pwd" end - end + end end def webserv_base_cgi #web url for local webserv (localhost, or hostname) if defined? @rc['webserv_cgi']['host'] and not @rc['webserv_cgi']['host'].nil? @@ -1343,13 +1343,13 @@ module SiSU_Env "#{http}#{@rc['webserv_cgi']['host']}:#{webserv_port_cgi}" else "#{http}#{@rc['webserv_cgi']['host']}" end - else + else http=webserv_host_base=~/http:\/\// ? '' : 'http://' if webserv_port_cgi "#{http}#{webserv_host_base}:#{webserv_port_cgi}" else "#{http}#{webserv_host_base}" end - end + end end def webrick #must have a port #REMOVE #port=":#{webserv_port_cgi}" @@ -1362,7 +1362,7 @@ module SiSU_Env elsif webserv_host_base and not webserv_host_base.nil? "#{http}#{webserv_host_base}" else "#{http}localhost" - end + end end def webserv #web url for local webserv (localhost, or hostname) if path.webserv_dir and path.webserv =~ /#{path.webserv_dir}/ #revisit @@ -2451,7 +2451,7 @@ module SiSU_Env end end filename_homepage=File.new("#{@env.path.webserv}/#{@env.path.stub_pwd}/index.html",'w') - filename_homepage_toc=File.new("#{@env.path.webserv}/#{@env.path.stub_pwd}/toc.html",'w') + filename_homepage_toc=File.new("#{@env.path.webserv}/#{@env.path.stub_pwd}/toc.html",'w') filename_homepage << @vz_home.index filename_homepage_toc << @vz_home.index end diff --git a/lib/sisu/v0/texinfo.rb b/lib/sisu/v0/texinfo.rb index 88f91d7d..c46f81ba 100644 --- a/lib/sisu/v0/texinfo.rb +++ b/lib/sisu/v0/texinfo.rb @@ -402,7 +402,7 @@ module SiSU_TexInfo if @md.fns =~/\.[_-]?sst$/ m=/(.+?)\.([_-]?sst)$/.match(@md.fns) fnb,sfx=m[1],m[2] - pwd=Dir.pwd + pwd=Dir.pwd case sfx when /[_-]?sst$/ @env=SiSU_Env::Info_env.new(@md.fns,@md.cmd) diff --git a/lib/sisu/v0/wikispeak.rb b/lib/sisu/v0/wikispeak.rb index b8ad1267..bcc2da04 100644 --- a/lib/sisu/v0/wikispeak.rb +++ b/lib/sisu/v0/wikispeak.rb @@ -263,7 +263,7 @@ WOK if para =~/^0~(\S+)\s+(.+?)\Z/m # for headers d_meta=SiSU_text_utils::Header_scan.new(@md,para).meta if d_meta; wiki_metadata(d_meta) - end + end end if para !~/(^0~||)/ if para =~@regx #/.+?<~\d+;\w\d+;\w\d+>.*/ #watch change diff --git a/lib/sisu/v0/xhtml.rb b/lib/sisu/v0/xhtml.rb index 40d8ade2..20fa702a 100644 --- a/lib/sisu/v0/xhtml.rb +++ b/lib/sisu/v0/xhtml.rb @@ -287,7 +287,7 @@ WOK if para =~/^0~(\S+)\s+(.+?)$/ # for headers d_meta=SiSU_text_utils::Header_scan.new(@md,para).meta if d_meta; xml_head(d_meta) - end + end end @rcdc=true if @rcdc==false and (para =~/~metadata/ or para =~/1~\s+Document Information/) if para !~/(^0~||)/ diff --git a/lib/sisu/v0/xml.rb b/lib/sisu/v0/xml.rb index 86dfd3cd..d9070dc1 100644 --- a/lib/sisu/v0/xml.rb +++ b/lib/sisu/v0/xml.rb @@ -311,7 +311,7 @@ WOK if para =~/^0~(\S+)\s+(.+?)$/ # for headers d_meta=SiSU_text_utils::Header_scan.new(@md,para).meta if d_meta; xml_head(d_meta) - end + end end @rcdc=true if @rcdc==false and (para =~/~metadata/ or para =~/1~\s+Document Information/) if para !~/(^0~||)/ diff --git a/lib/sisu/v0/xml_dom.rb b/lib/sisu/v0/xml_dom.rb index dd995dcf..82d882e0 100644 --- a/lib/sisu/v0/xml_dom.rb +++ b/lib/sisu/v0/xml_dom.rb @@ -336,7 +336,7 @@ WOK if para =~/^0~(\S+)\s+(.+?)$/ # for headers d_meta=SiSU_text_utils::Header_scan.new(@md,para).meta if d_meta; xml_head(d_meta) - end + end end @rcdc=true if @rcdc==false and (para =~/~metadata/ or para =~/1~\s+Document Information/) if para !~/(^0~||)/ -- cgit v1.2.3