aboutsummaryrefslogtreecommitdiffhomepage
path: root/lib/sisu/v4
diff options
context:
space:
mode:
authorRalph Amissah <ralph@amissah.com>2012-10-03 00:16:59 -0400
committerRalph Amissah <ralph@amissah.com>2012-10-03 00:16:59 -0400
commitf6bc7d81dee102b438a9118a66a2f2a86382c729 (patch)
tree36fe1d991dbbcb34426bd17afa212086be937994 /lib/sisu/v4
parentv4: bin/sisu $0, make possible to run sisu command on/within project dir tree (diff)
v4: bin/sisu $*, hub, make possible to specify dir path for markup files
* bin/sisu4 & bin/sisu3 now syslinks to bin/sisu
Diffstat (limited to 'lib/sisu/v4')
-rw-r--r--lib/sisu/v4/concordance.rb4
-rw-r--r--lib/sisu/v4/css.rb2
-rw-r--r--lib/sisu/v4/dal_syntax.rb2
-rw-r--r--lib/sisu/v4/epub.rb6
-rw-r--r--lib/sisu/v4/epub_concordance.rb4
-rw-r--r--lib/sisu/v4/epub_format.rb10
-rw-r--r--lib/sisu/v4/epub_segments.rb2
-rw-r--r--lib/sisu/v4/epub_tune.rb2
-rw-r--r--lib/sisu/v4/harvest_authors.rb4
-rw-r--r--lib/sisu/v4/harvest_topics.rb4
-rw-r--r--lib/sisu/v4/html.rb6
-rw-r--r--lib/sisu/v4/html_format.rb8
-rw-r--r--lib/sisu/v4/html_promo.rb6
-rw-r--r--lib/sisu/v4/html_scroll.rb2
-rw-r--r--lib/sisu/v4/html_segments.rb2
-rw-r--r--lib/sisu/v4/html_tune.rb2
-rw-r--r--lib/sisu/v4/manifest.rb2
-rw-r--r--lib/sisu/v4/manpage.rb4
-rw-r--r--lib/sisu/v4/manpage_format.rb2
-rw-r--r--lib/sisu/v4/odf.rb2
-rw-r--r--lib/sisu/v4/odf_format.rb4
-rw-r--r--lib/sisu/v4/plaintext.rb2
-rw-r--r--lib/sisu/v4/plaintext_format.rb2
-rw-r--r--lib/sisu/v4/po4a.rb2
-rw-r--r--lib/sisu/v4/qrcode.rb2
-rw-r--r--lib/sisu/v4/shared_html_lite.rb2
-rw-r--r--lib/sisu/v4/shared_xml.rb2
-rw-r--r--lib/sisu/v4/sst_to_s_xml_sax.rb2
-rw-r--r--lib/sisu/v4/sysenv.rb196
-rw-r--r--lib/sisu/v4/texinfo.rb4
-rw-r--r--lib/sisu/v4/texinfo_format.rb2
-rw-r--r--lib/sisu/v4/texpdf.rb2
-rw-r--r--lib/sisu/v4/texpdf_format.rb6
-rw-r--r--lib/sisu/v4/wikispeak.rb4
-rw-r--r--lib/sisu/v4/xhtml.rb2
-rw-r--r--lib/sisu/v4/xhtml_table.rb2
-rw-r--r--lib/sisu/v4/xml.rb2
-rw-r--r--lib/sisu/v4/xml_dom.rb2
-rw-r--r--lib/sisu/v4/xml_format.rb12
-rw-r--r--lib/sisu/v4/xml_tables.rb6
40 files changed, 181 insertions, 153 deletions
diff --git a/lib/sisu/v4/concordance.rb b/lib/sisu/v4/concordance.rb
index 84245643..15bd2dbe 100644
--- a/lib/sisu/v4/concordance.rb
+++ b/lib/sisu/v4/concordance.rb
@@ -112,7 +112,7 @@ module SiSU_Concordance
@particulars,@md=particulars,particulars.md
@data=SiSU_HTML::Source::HTML_Environment.new(particulars).tuned_file_instructions
@file=SiSU_Env::FileOp.new(@md)
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
txt_path=%{#{@md.dir_out}}
SiSU_Env::InfoSkin.new(@md).select
@fnb=@md.fnb
@@ -197,7 +197,7 @@ WOK
def initialize(particulars)
@particulars=particulars
begin
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
@env,@md,@dal_array=particulars.env,particulars.md,particulars.dal_array
@file=SiSU_Env::FileOp.new(@md)
@freq=Hash.new(0)
diff --git a/lib/sisu/v4/css.rb b/lib/sisu/v4/css.rb
index 693236c4..0b43edcc 100644
--- a/lib/sisu/v4/css.rb
+++ b/lib/sisu/v4/css.rb
@@ -152,7 +152,7 @@ module SiSU_Style
end
class CSS
def initialize
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
end
def fonts
@vz.font_fonts
diff --git a/lib/sisu/v4/dal_syntax.rb b/lib/sisu/v4/dal_syntax.rb
index b21f94a5..4a9dcbd4 100644
--- a/lib/sisu/v4/dal_syntax.rb
+++ b/lib/sisu/v4/dal_syntax.rb
@@ -64,7 +64,7 @@ module SiSU_DAL_Syntax
class Markup
def initialize(md='',data='')
@data,@md=data,md
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
@data_new=[]
url_and_stub=SiSU_Env::InfoEnv.new.url
@output_url="#{url_and_stub.remote}"
diff --git a/lib/sisu/v4/epub.rb b/lib/sisu/v4/epub.rb
index a4dce6ab..151d30f3 100644
--- a/lib/sisu/v4/epub.rb
+++ b/lib/sisu/v4/epub.rb
@@ -132,7 +132,7 @@ module SiSU_EPUB
def initialize(particulars)
@particulars=particulars
@md,@env=particulars.md,particulars.env
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
@env,@css=particulars.env,SiSU_Style::CSS.new
end
def directories
@@ -187,7 +187,7 @@ module SiSU_EPUB
@@firstseg=nil
def initialize(md=nil,data='')
@md,@data=md,data
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
@epub=SiSU_EPUB_Format::HeadInformation.new(@md)
@tell=SiSU_Screen::Ansi.new(@md.opt.cmd) if @md
@make=SiSU_Env::ProcessingSettings.new(@md)
@@ -478,7 +478,7 @@ module SiSU_EPUB
class ScrollHeadAndSegToc < Toc
def initialize(md='',toc='',links_guide_toc='')
@md,@toc,@links_guide_toc=md,toc,links_guide_toc
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
end
def in_common
toc_shared=[]
diff --git a/lib/sisu/v4/epub_concordance.rb b/lib/sisu/v4/epub_concordance.rb
index b8db317d..f6efa076 100644
--- a/lib/sisu/v4/epub_concordance.rb
+++ b/lib/sisu/v4/epub_concordance.rb
@@ -99,7 +99,7 @@ module SiSU_EPUB_Concordance
def initialize(particulars)
@particulars,@md=particulars,particulars.md
@data=SiSU_EPUB::Source::XHTML_Environment.new(particulars).tuned_file_instructions
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
txt_path=%{#{@md.dir_out}}
SiSU_Env::InfoSkin.new(@md).select
@fnb=@md.fnb
@@ -153,7 +153,7 @@ WOK
def initialize(particulars)
@particulars=particulars
begin
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
@env,@md,@dal_array=particulars.env,particulars.md,particulars.dal_array
@path="#{@env.processing_path.epub}"
@freq=Hash.new(0)
diff --git a/lib/sisu/v4/epub_format.rb b/lib/sisu/v4/epub_format.rb
index 70636fb1..15028362 100644
--- a/lib/sisu/v4/epub_format.rb
+++ b/lib/sisu/v4/epub_format.rb
@@ -61,7 +61,7 @@ module SiSU_EPUB_Format
def initialize(md,ocn)
@md,@ocn=md,ocn.to_s
@ocn ||=''
- vz=SiSU_Env::GetInit.instance.skin
+ vz=SiSU_Env::GetInit.new.skin
end
def ocn_display
@make=SiSU_Env::ProcessingSettings.new(@md)
@@ -1223,7 +1223,7 @@ WOK
def initialize(md)
@md=md
# DublinCore 1 - title
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
@css=SiSU_Env::CSS_Stylesheet.new(md)
@seg_name_xhtml=(SiSU_EPUB::Source::Seg.new.seg_name_xhtml || [])
@seg_name_xhtml_tracker=(SiSU_EPUB::Source::Seg.new.seg_name_xhtml_tracker || [])
@@ -1802,7 +1802,7 @@ WOK
end
end
class FormatTextObject
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
attr_accessor :md,:t_o,:txt,:ocn,:format,:table,:link,:linkname,:paranum,:p_num,:headname,:banner,:url
def initialize(md,t_o)
@md,@t_o=md,t_o
@@ -1846,7 +1846,7 @@ WOK
@txt=@txt.gsub(/#{Mx[:mk_o]}[-~]##{Mx[:mk_c]}/,'')
end
@p_num=ParagraphNumber.new(@md,@ocn)
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
end
def nametags_seg(dob) #FIX
tags=''
@@ -2049,7 +2049,7 @@ WOK
class FormatScroll < FormatTextObject
def initialize(md,txt)
super(md,txt)
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
end
end
class FormatSeg < FormatTextObject
diff --git a/lib/sisu/v4/epub_segments.rb b/lib/sisu/v4/epub_segments.rb
index 5a3f3092..8182690a 100644
--- a/lib/sisu/v4/epub_segments.rb
+++ b/lib/sisu/v4/epub_segments.rb
@@ -128,7 +128,7 @@ WOK
attr_reader :seg_name_xhtml,:seg_name_xhtml_tracker
def initialize(md='',data='')
@md,@data=md,data
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
@seg_name_xhtml=@@seg_name_xhtml || nil
@seg_name_xhtml_tracker=@@tracker || nil
@make=SiSU_Env::ProcessingSettings.new(@md) if @md
diff --git a/lib/sisu/v4/epub_tune.rb b/lib/sisu/v4/epub_tune.rb
index 1362815e..c98f6c52 100644
--- a/lib/sisu/v4/epub_tune.rb
+++ b/lib/sisu/v4/epub_tune.rb
@@ -196,7 +196,7 @@ module SiSU_EPUB_Tune
class Tune
def initialize(data,md)
@data,@md=data,md
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
@env=SiSU_Env::InfoEnv.new(@md.fns)
@sys=SiSU_Env::SystemCall.new
@env=SiSU_Env::InfoEnv.new(@md.fns)
diff --git a/lib/sisu/v4/harvest_authors.rb b/lib/sisu/v4/harvest_authors.rb
index 1846584a..ec2e014e 100644
--- a/lib/sisu/v4/harvest_authors.rb
+++ b/lib/sisu/v4/harvest_authors.rb
@@ -172,11 +172,11 @@ module SiSU_HarvestAuthors
def initialize(opt,the_idx)
@opt,@the_idx=opt,the_idx
@env=SiSU_Env::InfoEnv.new
- @rc=SiSU_Env::GetInit.instance.sisu_yaml.rc
+ @rc=SiSU_Env::GetInit.new.sisu_yaml.rc
@alphabet_list=%W[9 A B C D E F G H I J K L M N O P Q R S T U V W X Y Z]
@alph=@alphabet_list.dup
@letter=@alph.shift
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
end
def html_file_open
@the_idx.keys.each do |lng|
diff --git a/lib/sisu/v4/harvest_topics.rb b/lib/sisu/v4/harvest_topics.rb
index 762f4be0..f472fc0d 100644
--- a/lib/sisu/v4/harvest_topics.rb
+++ b/lib/sisu/v4/harvest_topics.rb
@@ -447,11 +447,11 @@ module SiSU_HarvestTopics
def initialize(opt,the_idx)
@opt,@the_idx=opt,the_idx
@env=SiSU_Env::InfoEnv.new
- @rc=SiSU_Env::GetInit.instance.sisu_yaml.rc
+ @rc=SiSU_Env::GetInit.new.sisu_yaml.rc
@alphabet_list=%W[9 A B C D E F G H I J K L M N O P Q R S T U V W X Y Z]
@alph=@alphabet_list.dup
@letter=@alph.shift
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
end
def html_file_open
@the_idx.keys.each do |lng|
diff --git a/lib/sisu/v4/html.rb b/lib/sisu/v4/html.rb
index 132394d6..d65a8ed3 100644
--- a/lib/sisu/v4/html.rb
+++ b/lib/sisu/v4/html.rb
@@ -138,7 +138,7 @@ module SiSU_HTML
def initialize(particulars)
@particulars=particulars
@md,@env=particulars.md,particulars.env
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
@env,@css=particulars.env,SiSU_Style::CSS.new
end
def tuned_file_instructions
@@ -223,7 +223,7 @@ module SiSU_HTML
@@firstseg=nil
def initialize(md=nil,data='')
@data,@md=data,md
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
@tell=SiSU_Screen::Ansi.new(@md.opt.cmd) if @md
end
def songsheet #extracts toc for scroll & seg
@@ -515,7 +515,7 @@ WOK
class ScrollHeadAndSegToc < Toc
def initialize(md='',toc='',links_guide_toc='')
@md,@toc,@links_guide_toc=md,toc,links_guide_toc
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
@make=SiSU_Env::ProcessingSettings.new(@md)
end
def in_common
diff --git a/lib/sisu/v4/html_format.rb b/lib/sisu/v4/html_format.rb
index fa9ac462..eb39eead 100644
--- a/lib/sisu/v4/html_format.rb
+++ b/lib/sisu/v4/html_format.rb
@@ -97,7 +97,7 @@ module SiSU_HTML_Format
def initialize(md)
@md=md
# DublinCore 1 - title
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
@seg_name_html=(SiSU_HTML::Source::Seg.new.seg_name_html || [])
@seg_name_html_tracker=(SiSU_HTML::Source::Seg.new.seg_name_html_tracker || [])
@metalink='#metadata'
@@ -861,7 +861,7 @@ WOK
end
end
class FormatTextObject
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
attr_accessor :md,:t_o,:txt,:ocn,:format,:table,:link,:linkname,:paranum,:p_num,:headname,:banner,:url
def initialize(md,t_o)
@md,@t_o=md,t_o
@@ -893,7 +893,7 @@ WOK
@txt=@txt.gsub(/#{Mx[:mk_o]}[-~]##{Mx[:mk_c]}/,'')
end
@p_num=ParagraphNumber.new(@md,@ocn)
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
@make=SiSU_Env::ProcessingSettings.new(@md)
end
def nametags_scroll(dob)
@@ -1141,7 +1141,7 @@ WOK
class FormatScroll < FormatTextObject
def initialize(md,txt)
super(md,txt)
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
end
end
class FormatSeg < FormatTextObject
diff --git a/lib/sisu/v4/html_promo.rb b/lib/sisu/v4/html_promo.rb
index 387da244..2cde2a44 100644
--- a/lib/sisu/v4/html_promo.rb
+++ b/lib/sisu/v4/html_promo.rb
@@ -62,9 +62,9 @@ module SiSU_HTML_Promo
def initialize(md)
@md=md
@env=SiSU_Env::InfoEnv.new(@md.fns,@md)
- @rc=SiSU_Env::GetInit.instance.sisu_yaml.rc
- @ad=SiSU_Env::GetInit.instance.ads
- @vz=SiSU_Env::GetInit.instance.skin
+ @rc=SiSU_Env::GetInit.new.sisu_yaml.rc
+ @ad=SiSU_Env::GetInit.new.ads
+ @vz=SiSU_Env::GetInit.new.skin
@flag=@env.widget.promo?
@make=SiSU_Env::ProcessingSettings.new(@md)
end
diff --git a/lib/sisu/v4/html_scroll.rb b/lib/sisu/v4/html_scroll.rb
index 170285cf..6755fc9b 100644
--- a/lib/sisu/v4/html_scroll.rb
+++ b/lib/sisu/v4/html_scroll.rb
@@ -63,7 +63,7 @@ module SiSU_HTML_Scroll
class Scroll
def initialize(md='',data='',endnotes='')
@md,@data,@endnotes=md,data,endnotes
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
end
def songsheet
begin
diff --git a/lib/sisu/v4/html_segments.rb b/lib/sisu/v4/html_segments.rb
index 81bb08d4..d41b77c7 100644
--- a/lib/sisu/v4/html_segments.rb
+++ b/lib/sisu/v4/html_segments.rb
@@ -149,7 +149,7 @@ module SiSU_HTML_Seg
attr_reader :seg_name_html,:seg_name_html_tracker
def initialize(md=nil,data='')
@md,@data=md,data
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
@seg_name_html=@@seg_name_html || nil
@seg_name_html_tracker=@@tracker || nil
@env=SiSU_Env::InfoEnv.new(@md.fns) if @md
diff --git a/lib/sisu/v4/html_tune.rb b/lib/sisu/v4/html_tune.rb
index 05126ede..ea558540 100644
--- a/lib/sisu/v4/html_tune.rb
+++ b/lib/sisu/v4/html_tune.rb
@@ -197,7 +197,7 @@ module SiSU_HTML_Tune
class Tune
def initialize(data,md)
@data,@md=data,md
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
@env=SiSU_Env::InfoEnv.new(@md.fns)
@sys=SiSU_Env::SystemCall.new
@env=SiSU_Env::InfoEnv.new(@md.fns)
diff --git a/lib/sisu/v4/manifest.rb b/lib/sisu/v4/manifest.rb
index 58f2d8eb..87798fdf 100644
--- a/lib/sisu/v4/manifest.rb
+++ b/lib/sisu/v4/manifest.rb
@@ -771,7 +771,7 @@ WOK
begin
minitoc=SiSU_HTML_MiniToc::TocMini.new(@md,data).songsheet.join("\n")
id,file='',''
- vz=SiSU_Env::GetInit.instance.skin
+ vz=SiSU_Env::GetInit.new.skin
search_form=if @f.build.search_form?
"<td>#{@env.widget_static.search_form}</td>"
else ''
diff --git a/lib/sisu/v4/manpage.rb b/lib/sisu/v4/manpage.rb
index 81f2ed2c..4d5e3144 100644
--- a/lib/sisu/v4/manpage.rb
+++ b/lib/sisu/v4/manpage.rb
@@ -109,7 +109,7 @@ module SiSU_Manpage
def initialize(md,data)
@md,@data=md,data
@brace_url=SiSU_Viz::Skin.new.url_decoration
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
@tab="\t"
@br="\n"
@@dostype='unix endnotes'
@@ -165,7 +165,7 @@ GSUB
end
def manpage_tail
SiSU_Env::InfoSkin.new(@md).select
- vz=SiSU_Env::GetInit.instance.skin
+ vz=SiSU_Env::GetInit.new.skin
generator="Generated by: #{@md.sisu_version[:project]} #{@md.sisu_version[:version]} of #{@md.sisu_version[:date_stamp]} (#{@md.sisu_version[:date]})" if @md.sisu_version[:version]
lastdone="Last Generated on: #{Time.now}"
rubyv="Ruby version: #{@md.ruby_version}"
diff --git a/lib/sisu/v4/manpage_format.rb b/lib/sisu/v4/manpage_format.rb
index a102b094..1f44b63b 100644
--- a/lib/sisu/v4/manpage_format.rb
+++ b/lib/sisu/v4/manpage_format.rb
@@ -78,7 +78,7 @@ module SiSU_ManpageFormat
@md,@dob=md,dob
rgx=/#{Mx[:en_a_o]}[\d*+]+\s+(.+?)#{Mx[:en_a_c]}/
@dob.obj.gsub!(rgx,'\1') if @dob.obj =~rgx
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
end
def scr_endnote_body
"<endnote>#{@dob.obj}</endnote> "
diff --git a/lib/sisu/v4/odf.rb b/lib/sisu/v4/odf.rb
index 807d2832..4381bfc5 100644
--- a/lib/sisu/v4/odf.rb
+++ b/lib/sisu/v4/odf.rb
@@ -106,7 +106,7 @@ module SiSU_ODF
@@fns=nil
def initialize(particulars)
@md,@env,@dal_array=particulars.md,particulars.env,particulars.dal_array
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
@tab="\t"
@brace_url=SiSU_Viz::Skin.new.url_decoration
@br=(@md.opt.cmd =~/M/) ? '' : ''
diff --git a/lib/sisu/v4/odf_format.rb b/lib/sisu/v4/odf_format.rb
index adfcf684..edde88ff 100644
--- a/lib/sisu/v4/odf_format.rb
+++ b/lib/sisu/v4/odf_format.rb
@@ -135,7 +135,7 @@ module SiSU_ODF_Format
end
rgx=/#{Mx[:en_a_o]}\d+\s+(.+?)#{Mx[:en_a_c]}/
@txt=@txt.gsub(rgx,'\1') if @txt =~rgx
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
end
def scr_endnote_body
"<endnote>#{@txt}</endnote> "
@@ -160,7 +160,7 @@ module SiSU_ODF_Format
def initialize(md,dob,p_num)
@md,@dob,@p_num=md,dob,p_num
@txt=dob.obj
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
if @md.fns != @@fns
@@table_counter=0
@@fns=@md.fns
diff --git a/lib/sisu/v4/plaintext.rb b/lib/sisu/v4/plaintext.rb
index c86fddb9..9e5719b7 100644
--- a/lib/sisu/v4/plaintext.rb
+++ b/lib/sisu/v4/plaintext.rb
@@ -190,7 +190,7 @@ WOK
def plaintext_tail
SiSU_Env::InfoSkin.new(@md).select
# env=SiSU_Env::InfoEnv.new(@md.fns)
- vz=SiSU_Env::GetInit.instance.skin
+ vz=SiSU_Env::GetInit.new.skin
base_url="#{@env.url.root}/#{@md.fnb}"
generator="Generated by: #{@md.sisu_version[:project]} #{@md.sisu_version[:version]} of #{@md.sisu_version[:date_stamp]} (#{@md.sisu_version[:date]})" if @md.sisu_version[:version]
lastdone="Last Generated on: #{Time.now}"
diff --git a/lib/sisu/v4/plaintext_format.rb b/lib/sisu/v4/plaintext_format.rb
index fe24112d..d98511d2 100644
--- a/lib/sisu/v4/plaintext_format.rb
+++ b/lib/sisu/v4/plaintext_format.rb
@@ -88,7 +88,7 @@ module SiSU_PlaintextFormat
@txt=@txt.gsub(rgx,'') if @txt =~rgx
rgx=/#{Mx[:en_a_o]}[\d*+]+\s+(.+?)#{Mx[:en_a_c]}/
@txt=@txt.gsub(rgx,'\1') if @txt =~rgx
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
end
def scr_endnote_body
"<endnote>#{@txt}</endnote> "
diff --git a/lib/sisu/v4/po4a.rb b/lib/sisu/v4/po4a.rb
index 53bab960..534569f5 100644
--- a/lib/sisu/v4/po4a.rb
+++ b/lib/sisu/v4/po4a.rb
@@ -170,7 +170,7 @@ module SiSU_Po4a
? md_src
: md_trn
@brace_url=SiSU_Viz::Skin.new.url_decoration
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
@tab="\t"
@@endnotes_=(@md.opt.mod.inspect =~/--endnote/) ? true : false # --footnote
@br=(@md.opt.mod.inspect =~/--dos/) ? "\r\n" : "\n" # --unix
diff --git a/lib/sisu/v4/qrcode.rb b/lib/sisu/v4/qrcode.rb
index 0d126266..151b38d2 100644
--- a/lib/sisu/v4/qrcode.rb
+++ b/lib/sisu/v4/qrcode.rb
@@ -707,7 +707,7 @@ WOK
def check_output(data)
begin
id,file='',''
- vz=SiSU_Env::GetInit.instance.skin
+ vz=SiSU_Env::GetInit.new.skin
@f=SiSU_Env::FileOp.new(@md) #.base_filename
url=@f.output_path.base.url
@en_manifest=if @env.output_dir_structure.by_language_code?
diff --git a/lib/sisu/v4/shared_html_lite.rb b/lib/sisu/v4/shared_html_lite.rb
index 02326334..8afb14c9 100644
--- a/lib/sisu/v4/shared_html_lite.rb
+++ b/lib/sisu/v4/shared_html_lite.rb
@@ -79,7 +79,7 @@ module SiSU_FormatShared
@tab="\t"
@brace_url=SiSU_Viz::Skin.new.url_decoration
@@tablehead,@@tablefoot=[],[]
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
@env=SiSU_Env::InfoEnv.new(@md.fns)
@base_url="#{@env.url.root}/#{@md.fnb}/#{@hname}.html"
end
diff --git a/lib/sisu/v4/shared_xml.rb b/lib/sisu/v4/shared_xml.rb
index 6860d80c..6c5b29ba 100644
--- a/lib/sisu/v4/shared_xml.rb
+++ b/lib/sisu/v4/shared_xml.rb
@@ -646,7 +646,7 @@ module SiSU_XML_Tags #Format
end
content=meta_content_clean(@md.keywords)
@keywords=%{ <meta name="keywords" content="#{content}" />\n} if @md.keywords
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
end
def meta_content_clean(content='')
content
diff --git a/lib/sisu/v4/sst_to_s_xml_sax.rb b/lib/sisu/v4/sst_to_s_xml_sax.rb
index cc08be70..fc41aff1 100644
--- a/lib/sisu/v4/sst_to_s_xml_sax.rb
+++ b/lib/sisu/v4/sst_to_s_xml_sax.rb
@@ -139,7 +139,7 @@ module SiSU_SimpleXML_ModelSax
@@xml={ body: [], open: [], close: [], head: [] }
def initialize(data='',particulars='')
@data,@env,@md=data,particulars.env,particulars.md
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
@regx=/^(?:#{Mx[:mk_o]}:p[bn]#{Mx[:mk_c]}\s*)?(?:#{Mx[:lv_o]}[1-9]:(\S*)#{Mx[:lv_c]})?(.+)/
@tab="\t"
if @md
diff --git a/lib/sisu/v4/sysenv.rb b/lib/sisu/v4/sysenv.rb
index 90df10fa..286fa408 100644
--- a/lib/sisu/v4/sysenv.rb
+++ b/lib/sisu/v4/sysenv.rb
@@ -90,9 +90,8 @@ module SiSU_Env
YEAR
end
end
- class InfoSystem
+ class InfoSystemGen
require 'rbconfig'
- include Singleton
@@user,@@home,@@hostname,@@pwd,@@sisu_etc,@@host,@@arch,@@rbver,@@dir_arch,@@dir_sitearch,@@dir_bin,@@locale,@@rc,@@sisurc_path,@@ad=ENV['USER'],ENV['HOME'],ENV['HOSTNAME'],ENV['PWD'],Config::CONFIG['sysconfdir'] + '/sisu',Config::CONFIG['host'],Config::CONFIG['arch'],%x{ruby -v}.strip,Config::CONFIG['archdir'],Config::CONFIG['sitearchdir'],Config::CONFIG['bindir'],%x{locale charmap}.strip,nil,nil,{} # %x{ruby -v}.strip # Config::CONFIG['rb_ver']
out=Config::CONFIG['localstatedir']
etc=Config::CONFIG['sysconfdir'] + '/sisu'
@@ -214,31 +213,21 @@ module SiSU_Env
}
@@default_dir=DEFAULT_DIR
m=/.+\/(?:src\/)?(\S+)/m # m=/.+?\/(?:src\/)?([^\/]+)$/im # m=/.+\/(\S+)/m
- stub_pwd=@@pwd[m,1]
- @@rc_path=[
- "#{@@pwd}/.sisu/#{SiSU_version_dir}",
- "#{@@pwd}/.sisu",
- "#{@@pwd}/_sisu/#{SiSU_version_dir}",
- "#{@@pwd}/_sisu",
- "#{@@home}/.sisu/#{SiSU_version_dir}",
- "#{@@home}/.sisu",
- "#{@@sisu_etc}/#{SiSU_version_dir}",
- ]
- @@ad_path=(stub_pwd !~/^sisupod$/) \
- ? ([
- "#{@@pwd}/.sisu/skin/yml",
- "#{@@pwd}/_sisu/skin/yml",
- "#{@@home}/.sisu/skin/yml",
- "#{@@sisu_etc}/skin/yml",
- ])
- : ["#{@@home}/.sisu",@@sisu_etc]
+ @@pwd=@pwd=(/(\S+?)(?:\/(?:#{Px[:lng_lst_rgx]}))?$/).match(Dir.pwd)[1]
+ stub_pwd=@pwd[m,1]
attr_accessor :user,:home,:hostname,:pwd,:host,:arch,:rbver,:dir_arch,:dir_sitearch,:dir_bin,:locale,:webserv_path,:webserv_host_cgi,:webserv_port_cgi,:default_dir,:rc_path,:ad_path
def initialize
- @user,@home,@hostname,@pwd,@sisu_etc,@host,@arch,@rbver,@dir_arch,@dir_sitearch,@dir_bin,@locale,@default_dir,@rc_path,@ad_path=\
- @@user,@@home,@@hostname,@@pwd,@@sisu_etc,@@host,@@arch,@@rbver,@@dir_arch,@@dir_sitearch,@@dir_bin,@@locale,@@default_dir,@@rc_path,@@ad_path
+ @user,@home,@hostname,@pwd,@sisu_etc,@host,@arch,@rbver,@dir_arch,@dir_sitearch,@dir_bin,@locale,@default_dir=\
+ @@user,@@home,@@hostname,@@pwd,@@sisu_etc,@@host,@@arch,@@rbver,@@dir_arch,@@dir_sitearch,@@dir_bin,@@locale,@@default_dir
#note rbver is duplicated in InfoVersion
end
end
+ class InfoSystem < InfoSystemGen
+ include Singleton
+ def initialize
+ super()
+ end
+ end
class Load
def initialize(prog,mandatory=false)
@prog,@mandatory=prog,mandatory
@@ -275,14 +264,20 @@ module SiSU_Env
load_prog
end
end
- class GetInit < InfoSystem
- include Singleton
+ class GetInit < InfoSystemGen
@@noyaml=false
@@rc,@@sisurc_path,@@vz,@@tx=nil,nil,nil,nil
@@ad={ promo: nil, promo_list: nil, flag_promo: false }
+ @@sdmd=nil
attr_accessor :yaml
def initialize
super()
+ @markup_dir_changed_=if @@sdmd==$sisu_document_markup_directory
+ false
+ else
+ @@sdmd=$sisu_document_markup_directory
+ true
+ end
end
def skin
@@vz ||=SiSU_Viz::Skin.new
@@ -292,7 +287,17 @@ module SiSU_Env
end
def sisu_yaml
def rc
- unless @@rc
+ if @markup_dir_changed_
+ @rc_path=[
+ "#{$sisu_document_markup_directory}/.sisu/#{SiSU_version_dir}",
+ "#{$sisu_document_markup_directory}/.sisu",
+ "#{$sisu_document_markup_directory}/_sisu/#{SiSU_version_dir}",
+ "#{$sisu_document_markup_directory}/_sisu",
+ "#{@@home}/.sisu/#{SiSU_version_dir}",
+ "#{@@home}/.sisu",
+ "#{@@sisu_etc}/#{SiSU_version_dir}",
+ "#{@@sisu_etc}",
+ ]
@rc_path.each do |v|
if @@noyaml \
or FileTest.exist?("#{v}/noyaml")
@@ -303,16 +308,16 @@ module SiSU_Env
f='sisurc.yml'
if FileTest.exist?("#{v}/#{f}")
require 'yaml'
- @@sisurc_path="#{v}/#{f}"
- @@rc=YAML::load(File::open(@@sisurc_path))
+ @@sisurc_path=v
+ @@rc=YAML::load(File::open("#{@@sisurc_path}/#{f}"))
break
end
unless @@rc
f='sisurc.yaml'
if FileTest.exist?("#{v}/#{f}")
require 'yaml'
- @@sisurc_path="#{v}/#{f}"
- @@rc=YAML::load(File::open(@@sisurc_path))
+ @@sisurc_path=v
+ @@rc=YAML::load(File::open("#{@@sisurc_path}/#{f}"))
break
end
end
@@ -329,40 +334,52 @@ module SiSU_Env
end
def ads #WORK AREA
tell_no_yaml='WARNING - YAML loading switched off, to enable delete the file:'
- @ad_path.each do |v|
- if @@noyaml \
- or FileTest.exist?("#{v}/noyaml")
- puts tell_no_yaml + "\n\t#{v}/noyaml\n" unless @@noyaml
- @@noyaml=true
- break
- else
- if FileTest.exist?("#{v}/list.yml")
- unless @@ad[:promo_list]
- require 'yaml'
- @@ad[:promo_list] ||= YAML::load(File::open("#{v}/list.yml"))
- end
- @@ad[:flag_promo]=true
+ if @markup_dir_changed_
+ @ad_path=[
+ "#{$sisu_document_markup_directory}/.sisu/#{SiSU_version_dir}/skin/yml",
+ "#{$sisu_document_markup_directory}/.sisu/skin/yml",
+ "#{$sisu_document_markup_directory}/_sisu/#{SiSU_version_dir}/skin/yml",
+ "#{$sisu_document_markup_directory}/_sisu/skin/yml",
+ "#{@@home}/.sisu/#{SiSU_version_dir}/skin/yml",
+ "#{@@home}/.sisu/skin/yml",
+ "#{@@sisu_etc}/#{SiSU_version_dir}/skin/yml",
+ "#{@@sisu_etc}/skin/yml",
+ ]
+ @ad_path.each do |v|
+ if @@noyaml \
+ or FileTest.exist?("#{v}/noyaml")
+ puts tell_no_yaml + "\n\t#{v}/noyaml\n" unless @@noyaml
+ @@noyaml=true
break
+ else
+ if FileTest.exist?("#{v}/list.yml")
+ unless @@ad[:promo_list]
+ require 'yaml'
+ @@ad[:promo_list] ||= YAML::load(File::open("#{v}/list.yml"))
+ end
+ @@ad[:flag_promo]=true
+ break
+ end
+ @@ad[:flag_promo]=false
end
- @@ad[:flag_promo]=false
end
- end
- @ad_path.each do |v|
- if @@noyaml \
- or FileTest.exist?("#{v}/noyaml")
- puts tell_no_yaml + "\n\t#{v}/noyaml\n" unless @@noyaml
- @@noyaml=true
- break
- else
- if FileTest.exist?("#{v}/promo.yml")
- unless @@ad[:promo]
- require 'yaml'
- @@ad[:promo] ||= YAML::load(File::open("#{v}/promo.yml"))
- end
- @@ad[:flag_promo]=true
+ @ad_path.each do |v|
+ if @@noyaml \
+ or FileTest.exist?("#{v}/noyaml")
+ puts tell_no_yaml + "\n\t#{v}/noyaml\n" unless @@noyaml
+ @@noyaml=true
break
+ else
+ if FileTest.exist?("#{v}/promo.yml")
+ unless @@ad[:promo]
+ require 'yaml'
+ @@ad[:promo] ||= YAML::load(File::open("#{v}/promo.yml"))
+ end
+ @@ad[:flag_promo]=true
+ break
+ end
+ @@ad[:flag_promo]=false
end
- @@ad[:flag_promo]=false
end
end
@@ad
@@ -373,11 +390,11 @@ module SiSU_Env
@@ad={}
attr_accessor :rc,:fnn,:fnb,:fnt,:fnv,:fnz,:ad
def initialize(fns='')
- super()
@fns=fns
@sys=InfoSystem.instance
- @rc=GetInit.instance.sisu_yaml.rc
- @ad=GetInit.instance.ads
+ get_init=SiSU_Env::GetInit.new
+ @rc=get_init.sisu_yaml.rc
+ @ad=get_init.ads
if @fns \
and @fns != '' \
and @fns !=@@fns
@@ -1374,9 +1391,9 @@ module SiSU_Env
: false
end
def widget #needs (md) #move
- @rc=SiSU_Env::GetInit.instance.sisu_yaml.rc
- @ad=SiSU_Env::GetInit.instance.ads
- @vz=SiSU_Env::GetInit.instance.skin
+ @rc=SiSU_Env::GetInit.new.sisu_yaml.rc
+ @ad=SiSU_Env::GetInit.new.ads
+ @vz=SiSU_Env::GetInit.new.skin
@flag={ ad: false, md: false, sk: false, rc: false }
def promo?
@flag[:ad]=if @md.flag_promo && @ad[:flag_promo]
@@ -1449,7 +1466,7 @@ module SiSU_Env
end
end
def search_form(type='sisusearch',action=nil,db=nil,table=false)
- rc=SiSU_Env::GetInit.instance.sisu_yaml.rc
+ rc=SiSU_Env::GetInit.new.sisu_yaml.rc
create_form_sisu=if action \
and db \
and action =~/https?:\/\// \
@@ -1505,7 +1522,7 @@ WOK
form
end
def search_form_static(action=nil,db=nil)
- rc=SiSU_Env::GetInit.instance.sisu_yaml.rc
+ rc=SiSU_Env::GetInit.new.sisu_yaml.rc
create_form=if rc['search']['sisu']['flag']==true \
and action \
and db \
@@ -1553,8 +1570,8 @@ WOK
self
end
def widget_static
- @rc=SiSU_Env::GetInit.instance.sisu_yaml.rc
- @vz=SiSU_Env::GetInit.instance.skin
+ @rc=SiSU_Env::GetInit.new.sisu_yaml.rc
+ @vz=SiSU_Env::GetInit.new.skin
@flag={ ad: false, md: false, sk: false, rc: false }
def search?
flag=if defined? @rc['search'] \
@@ -1601,7 +1618,7 @@ WOK
end
end
def search_form(action=nil,db=nil)
- rc=SiSU_Env::GetInit.instance.sisu_yaml.rc
+ rc=SiSU_Env::GetInit.new.sisu_yaml.rc
create_form=if defined? rc['search']['sisu']['flag'] \
and rc['search']['sisu']['flag']==true \
and action \
@@ -1738,22 +1755,32 @@ WOK
end
self
end
- def read_source_file(fns)
+ def read_source_file_array(fns)
fns_array=unless fns =~/\.ssm.sst$/
IO.readlines(fns, mode: 'r:utf-8', cr_newline: true)
else
IO.readlines("#{processing_path.composite_file}/#{fns}", mode: 'r:utf-8', cr_newline: true)
end
end
+ def read_source_file(fns)
+ read_source_file_array(fns)
+ end
+ def read_source_file_string(fns)
+ fns_str=unless fns =~/\.ssm.sst$/
+ IO.read(fns, mode: 'r:utf-8', cr_newline: true)
+ else
+ IO.read("#{processing_path.composite_file}/#{fns}", mode: 'r:utf-8', cr_newline: true)
+ end
+ end
def source_file_processing_array(fns)
- sf=read_source_file(fns).join.split(/\s*\n\s*\n/m)
+ sf=read_source_file_string(fns).split(/\s*\n\s*\n/m)
end
def path #dir
def home
@sys.home
end
def sisurc_path
- GetInit.instance.sisu_yaml.rc_path
+ GetInit.new.sisu_yaml.rc_path
end
def pwd
@sys.pwd
@@ -1824,7 +1851,7 @@ WOK
@sys.rc_path
end
def yamlrc
- GetInit.instance.sisu_yaml.rc_path
+ GetInit.new.sisu_yaml.rc_path
end
def man #check use
(defined? @rc['webserv']['man']) \
@@ -2724,7 +2751,7 @@ WOK
class InfoProcessingFlag
attr_accessor :color,:cf_0,:cf_1,:cf_2,:cf_3,:cf_4,:cf_5
def initialize
- @rc=GetInit.instance.sisu_yaml.rc
+ @rc=GetInit.new.sisu_yaml.rc
end
def color #processing flag shortcuts
(defined? @rc['flag']['color']) ? @rc['flag']['color'] : false
@@ -2959,7 +2986,7 @@ WOK
end
class InfoRemoteHost
def initialize
- @rc=GetInit.instance.sisu_yaml.rc
+ @rc=GetInit.new.sisu_yaml.rc
end
def remote_host #see InfoRemote remote_host_base_general
r=[]
@@ -3043,7 +3070,7 @@ WOK
def initialize(opt)
super(opt) #
@opt=opt
- @rc=GetInit.instance.sisu_yaml.rc
+ @rc=GetInit.new.sisu_yaml.rc
end
def remote_host_base_general
SiSU_Env::InfoRemoteHost.new.remote_host
@@ -3396,7 +3423,9 @@ WOK
def get_version
@version={}
@pwd=ENV['PWD']
- yst_ver="#{defaults[:sisu_share]}/#{SiSU_version_dir}/v/version.yml"
+ yst_ver=SiSU_path_specified_Version_ \
+ ? SiSU_path_specified_Version_
+ : "#{defaults[:sisu_share]}/#{SiSU_version_dir}/v/version.yml"
lib_path=@@lib_path ? @@lib_path : `echo $RUBYLIB`.split(':')
@@lib_path ||=lib_path
if File.exist?(yst_ver); @version=YAML::load(File::open(yst_ver)) #unless @@noyaml
@@ -3493,7 +3522,7 @@ WOK
@md=md
end
def cnf_rc #sisurc.yml
- @rc=SiSU_Env::GetInit.instance.sisu_yaml.rc
+ @rc=SiSU_Env::GetInit.new.sisu_yaml.rc
end
def env_rc #env rc (including sisurc.yml)
@env_rc ||=SiSU_Env::InfoEnv.new(@md.fns)
@@ -3821,14 +3850,13 @@ WOK
class InfoDb < InfoEnv
@@rc=nil
def initialize
- @@pwd ||=Dir.pwd
- @pwd=Dir.pwd
+ @@pwd=@pwd=(/(\S+?)(?:\/(?:#{Px[:lng_lst_rgx]}))?$/).match(Dir.pwd)[1]
@env=SiSU_Env::InfoEnv.new
pt=Pathname.new(@pwd)
r=Px[:lng_lst_rgx]
u=/.+?\/([^\/]+)(?:\/(?:#{r})$|$)/
@pwd_stub=pt.realpath.to_s[u,1]
- @rc=@@rc ||=GetInit.instance.sisu_yaml.rc
+ @rc=@@rc ||=GetInit.new.sisu_yaml.rc
@defaults=SiSU_Env::InfoEnv.new.defaults
end
def share_source?
@@ -5630,7 +5658,7 @@ WOK
md.doc_skin
else nil
end
- @home,@pwd=ENV['HOME'],ENV['PWD']
+ @home,@pwd=ENV['HOME'],Dir.pwd
m=/.+\/(?:src\/)?(\S+)/m # m=/.+?\/(?:src\/)?([^\/]+)$/im # m=/.+\/(\S+)/m
@pwd_stub=@pwd[m,1]
@env=SiSU_Env::InfoEnv.new
@@ -5807,8 +5835,8 @@ WOK
@cmd=cmd
@env=SiSU_Env::InfoEnv.new
@home,@pwd=ENV['HOME'],ENV['PWD'] #@pwd=Dir.pwd
- @rc=GetInit.instance.sisu_yaml.rc
- @vz=SiSU_Env::GetInit.instance.skin
+ @rc=GetInit.new.sisu_yaml.rc
+ @vz=SiSU_Env::GetInit.new.skin
@vz_home=SiSU_Viz::Home.new
end
def homepage
diff --git a/lib/sisu/v4/texinfo.rb b/lib/sisu/v4/texinfo.rb
index fb54ceda..5305ceed 100644
--- a/lib/sisu/v4/texinfo.rb
+++ b/lib/sisu/v4/texinfo.rb
@@ -78,7 +78,7 @@ module SiSU_TexInfo
@opt=opt
@md=SiSU_Param::Parameters.new(@opt).get
@env=SiSU_Env::InfoEnv.new(@opt.fns)
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
end
def directories
begin
@@ -134,7 +134,7 @@ module SiSU_TexInfo
def initialize(md,data)
@md,@data=md,data
@env=SiSU_Env::InfoEnv.new(@md.fns)
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
@f=SiSU_Env::FileOp.new(@md)
end
def songsheet
diff --git a/lib/sisu/v4/texinfo_format.rb b/lib/sisu/v4/texinfo_format.rb
index 78f2a188..e79c3f38 100644
--- a/lib/sisu/v4/texinfo_format.rb
+++ b/lib/sisu/v4/texinfo_format.rb
@@ -73,7 +73,7 @@ module SiSU_TexInfoFormat
p dob.class
p caller
end
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
end
def head
t=Time.now
diff --git a/lib/sisu/v4/texpdf.rb b/lib/sisu/v4/texpdf.rb
index 0665c9b4..2c78ca61 100644
--- a/lib/sisu/v4/texpdf.rb
+++ b/lib/sisu/v4/texpdf.rb
@@ -290,7 +290,7 @@ module SiSU_TeX
@data=@particulars.dal_array # dal file drawn here
@st={ tex: {} }
@tex_ml=SiSU_TeX_Pdf::UseTeX.new(@md)
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
@dp=@@dp ||=SiSU_Env::InfoEnv.new.digest.pattern
@brace_url=SiSU_Viz::Skin.new.url_decoration
l=SiSU_Env::StandardiseLanguage.new(@md.opt.lng).language
diff --git a/lib/sisu/v4/texpdf_format.rb b/lib/sisu/v4/texpdf_format.rb
index 2bd558bc..77723f85 100644
--- a/lib/sisu/v4/texpdf_format.rb
+++ b/lib/sisu/v4/texpdf_format.rb
@@ -99,7 +99,7 @@ module SiSU_TeX_Pdf
else @center_begin,@center_end='',''
end
@start_table=''
- @tx=SiSU_Env::GetInit.instance.tex
+ @tx=SiSU_Env::GetInit.new.tex
@brace_rel=SiSU_Viz::Skin.new.rel_decoration
@env ||=SiSU_Env::InfoEnv.new(@md.fns)
@tex2pdf=@@tex3pdf ||=SiSU_Env::SystemCall.new.tex2pdf_engine
@@ -729,7 +729,7 @@ module SiSU_TeX_Pdf
p t_o.class
p caller
end
- @tx=SiSU_Env::GetInit.instance.tex
+ @tx=SiSU_Env::GetInit.new.tex
@brace_url=SiSU_Viz::Skin.new.url_decoration
@tex2pdf=@@tex3pdf ||=SiSU_Env::SystemCall.new.tex2pdf_engine
@ps=@txt if @txt=~/(?:a4|letter|legal|book|a5|b5)/i
@@ -1384,7 +1384,7 @@ WOK
attr_accessor :url,:txt,:date
def initialize(md)
@md=md
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
@date=SiSU_Env::InfoDate.new # #{@date.year}
@copymark='{\\begin{footnotesize}\\raisebox{1ex}{\\copyright}\\end{footnotesize}}'
@brace_url=SiSU_Viz::Skin.new.url_decoration
diff --git a/lib/sisu/v4/wikispeak.rb b/lib/sisu/v4/wikispeak.rb
index 725be0a5..9ac6cc37 100644
--- a/lib/sisu/v4/wikispeak.rb
+++ b/lib/sisu/v4/wikispeak.rb
@@ -149,7 +149,7 @@ module SiSU_Wikispeak
@@dp=nil
def initialize(data,md)
@data,@md=data,md
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
@dp=@@dp ||=SiSU_Env::InfoEnv.new.digest.pattern
@regx=/^(?:(?:#{Mx[:br_line]}\s*|#{Mx[:br_nl]}\s*)?#{Mx[:lv_o]}\d:(\S*?)#{Mx[:lv_c]}\s*)?(.+)/ #fix Mx[:lv_o] #m # 2004w18 pb pn removal added
@tab="\t"
@@ -178,7 +178,7 @@ WOK
end
def wiki_tail
SiSU_Env::InfoSkin.new(@md).select
- vz=SiSU_Env::GetInit.instance.skin
+ vz=SiSU_Env::GetInit.new.skin
generator="Generated by: #{@md.sisu_version[:project]} #{@md.sisu_version[:version]} of #{@md.sisu_version[:date_stamp]} (#{@md.sisu_version[:date]})" if @md.sisu_version[:version]
lastdone="Last Generated on: #{Time.now}"
rubyv="Ruby version: #{@md.ruby_version}"
diff --git a/lib/sisu/v4/xhtml.rb b/lib/sisu/v4/xhtml.rb
index e73b97b7..f78466b7 100644
--- a/lib/sisu/v4/xhtml.rb
+++ b/lib/sisu/v4/xhtml.rb
@@ -129,7 +129,7 @@ module SiSU_XHTML
@@xml={ body: [], sisu: [], open: [], close: [], head: [] }
def initialize(particulars)
@env,@md,@dal_array=particulars.env,particulars.md,particulars.dal_array
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
@tab="\t"
@trans=SiSU_XML_Munge::Trans.new(@md)
@sys=SiSU_Env::SystemCall.new
diff --git a/lib/sisu/v4/xhtml_table.rb b/lib/sisu/v4/xhtml_table.rb
index 30701433..e6a470f5 100644
--- a/lib/sisu/v4/xhtml_table.rb
+++ b/lib/sisu/v4/xhtml_table.rb
@@ -61,7 +61,7 @@ module SiSU_XHTML_Table
@@tablehead=0
@@tablefoot=[] #watch
def initialize(table)
- @table_obj,@vz=table,SiSU_Env::GetInit.instance.skin
+ @table_obj,@vz=table,SiSU_Env::GetInit.new.skin
end
def table
table_obj=@table_obj
diff --git a/lib/sisu/v4/xml.rb b/lib/sisu/v4/xml.rb
index 1346f33e..4c6a7332 100644
--- a/lib/sisu/v4/xml.rb
+++ b/lib/sisu/v4/xml.rb
@@ -128,7 +128,7 @@ module SiSU_XML_SAX
@@xml={ body: [], open: [], close: [], head: [] }
def initialize(particulars)
@env,@md,@dal_array=particulars.env,particulars.md,particulars.dal_array
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
@trans=SiSU_XML_Munge::Trans.new(@md)
@sys=SiSU_Env::SystemCall.new
end
diff --git a/lib/sisu/v4/xml_dom.rb b/lib/sisu/v4/xml_dom.rb
index 4508c389..80f7938a 100644
--- a/lib/sisu/v4/xml_dom.rb
+++ b/lib/sisu/v4/xml_dom.rb
@@ -127,7 +127,7 @@ module SiSU_XML_DOM
@@xml={ body: [], open: [], close: [], head: [], sc: [] }
def initialize(particulars)
@env,@md,@dal_array=particulars.env,particulars.md,particulars.dal_array
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
@trans=SiSU_XML_Munge::Trans.new(@md)
@sys=SiSU_Env::SystemCall.new
end
diff --git a/lib/sisu/v4/xml_format.rb b/lib/sisu/v4/xml_format.rb
index 52874eb1..50e90772 100644
--- a/lib/sisu/v4/xml_format.rb
+++ b/lib/sisu/v4/xml_format.rb
@@ -192,7 +192,7 @@ module SiSU_XML_Format
@copyright=%{<meta name="copyright" content="#{@md.rights.copyright.all}" />\n} if @md.rights.copyright.all # possibly redundant see dc.rights
@owner=%{<meta name="owner" content="#{@md.owner}" />\n} if @md.owner
@keywords=%{<meta name="keywords" content="#{@md.keywords}" />\n} if @md.keywords
- @vz=SiSU_Env::GetInit.instance.skin #margin,paragraph,table,banner,url,png,txt,color,font,nav_txt,nav_png,credits,js,php
+ @vz=SiSU_Env::GetInit.new.skin #margin,paragraph,table,banner,url,png,txt,color,font,nav_txt,nav_png,credits,js,php
@index='index'
end
def table_close
@@ -279,7 +279,7 @@ WOK
@lnk_url=@lnk_url.gsub(rgx,'') if @lnk_url =~rgx
rgx=/~\{\d+\s+(.+?)\}~/
@lnk_url=@lnk_url.gsub(rgx,'\1') if @lnk_url =~rgx
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
end
def scr_endnote_body
"<endnote>#{@txt}</endnote> "
@@ -357,7 +357,7 @@ WOK
@md=md
@rdf=SiSU_XML_Tags::RDF.new(md)
# DublinCore 1 - title
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
@stylesheet=SiSU_Style::CSS_HeadInfo.new(md).stylesheet
@seg_name_html=(SiSU_HTML::Source::Seg.new.seg_name_html || [])
@seg_name_html_tracker=(SiSU_HTML::Source::Seg.new.seg_name_html_tracker || [])
@@ -973,7 +973,7 @@ WOK
end
end
class FormatTextObject
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
attr_accessor :md,:dob,:txt,:ocn,:format,:table,:link,:linkname,:paranum,:p_num,:headname,:banner,:url
def initialize(md,t_o)
@md,@t_o=md,t_o
@@ -1019,7 +1019,7 @@ WOK
end
end
@dob=t_o if defined? t_o.is
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
end
def endnote_body
%{
@@ -1196,7 +1196,7 @@ WOK
class FormatScroll < FormatTextObject
def initialize(md,txt)
super(md,txt)
- @vz=SiSU_Env::GetInit.instance.skin
+ @vz=SiSU_Env::GetInit.new.skin
end
end
class FormatSeg < FormatTextObject
diff --git a/lib/sisu/v4/xml_tables.rb b/lib/sisu/v4/xml_tables.rb
index ba89e791..edf2a6be 100644
--- a/lib/sisu/v4/xml_tables.rb
+++ b/lib/sisu/v4/xml_tables.rb
@@ -62,7 +62,7 @@ module SiSU_Tables
@@tablehead=0
@@tablefoot=[] #watch #bug??? #check was @@tablefoot
def initialize(one,ocn='')
- @one,@parablock,@ocn,@vz=one,one,ocn,SiSU_Env::GetInit.instance.skin
+ @one,@parablock,@ocn,@vz=one,one,ocn,SiSU_Env::GetInit.new.skin
end
def table_split #% used but, no longer operational, revisit
@new_content=[]
@@ -77,7 +77,7 @@ module SiSU_Tables
@@tablehead=0
@@tablefoot=[]
def initialize(one,ocn='')
- @one,@parablock,@ocn,@vz=one,one,ocn,SiSU_Env::GetInit.instance.skin
+ @one,@parablock,@ocn,@vz=one,one,ocn,SiSU_Env::GetInit.new.skin
end
def table
m=@parablock[/<!f(.+?)!>/,1]
@@ -121,7 +121,7 @@ module SiSU_Tables
@@tablehead=0
@@tablefoot=[]
def initialize(one)
- @one,@parablock,@vz=one,one,SiSU_Env::GetInit.instance.skin
+ @one,@parablock,@vz=one,one,SiSU_Env::GetInit.new.skin
end
def table_head(inf)
%{<table summary="normal text css" width="100%" border="0" bgcolor="white" cellpadding="2" align="center">