diff options
author | Ralph Amissah <ralph.amissah@gmail.com> | 2022-03-17 11:49:22 -0400 |
---|---|---|
committer | Ralph Amissah <ralph@amissah.com> | 2022-04-06 16:12:40 -0400 |
commit | e481fdd4b3403d621380c43047484aeb3a3a46d2 (patch) | |
tree | 2d800ad8ea33c685bb280be521881c469dea0613 /org | |
parent | org-tangle files with new headers (diff) |
ruby variable passing breakage, make constant?
Diffstat (limited to 'org')
-rw-r--r-- | org/env.org | 2 | ||||
-rw-r--r-- | org/sisu-bin.org | 2 | ||||
-rw-r--r-- | org/xhtml.org | 8 | ||||
-rw-r--r-- | org/xml.org | 8 |
4 files changed, 15 insertions, 5 deletions
diff --git a/org/env.org b/org/env.org index 02c5ed29..28df5017 100644 --- a/org/env.org +++ b/org/env.org @@ -392,7 +392,7 @@ module SiSU_Create_Site cp_images(src,dest) if FileTest.directory?(src) end def cp_base_images #fix images - src=SiSU_is.path_base_system_data? + '/image' + src=$sisu_base_data + '/image' # hard fix, revisit dest_arr=[ "#{@env.path.webserv}/_sisu/image_sys", "#{@env.path.webserv}/#{@env.path.base_markup_dir_stub}/_sisu/image_sys" diff --git a/org/sisu-bin.org b/org/sisu-bin.org index a92e7b5e..1ee0d567 100644 --- a/org/sisu-bin.org +++ b/org/sisu-bin.org @@ -288,6 +288,8 @@ class Orient get_processing_info.processing_files.each_pair do |markup_dir,markup_file| begin $sisu_document_markup_directory=markup_dir.gsub(/\/$/,'') + $sisu_base_data=sisu_path_base_system_data # hard fix, revisit + $sisu_called_from=File.expand_path(processing.called_as) argv_sub=get_processing_info.command_line_modifiers + markup_file if FileTest.directory?(markup_dir) system("cd #{markup_dir}") diff --git a/org/xhtml.org b/org/xhtml.org index c24a5411..5c0a5cf0 100644 --- a/org/xhtml.org +++ b/org/xhtml.org @@ -1180,6 +1180,11 @@ module SiSU_XHTML_EPUB2 end end def images +#puts @md.env.path.image_source_include +#puts @md.env.processing_path.epub +#puts @md.env.path.image_source_include_local +puts @md.file.output_path.epub.rel_image + #img_pth=$sisu_base_data + '/image' img_pth=@md.env.path.image_source_include img_src_pth=unless @md.opt.f_pth[:pth] =~/\/\S+?\/sisupod\/\S+?\/sisupod\/doc/ @md.file.output_path.epub.rel_image @@ -1191,6 +1196,9 @@ module SiSU_XHTML_EPUB2 if FileTest.directory?("#{@md.env.processing_path.epub}/#{Ep[:d_oebps]}/image") \ && FileTest.file?("#{img_src_pth}/#{x}") FileUtils::cp("#{img_src_pth}/#{x}","#{@md.env.processing_path.epub}/#{Ep[:d_oebps]}/image") + #elsif FileTest.directory?("#{$sisu_base_data}/image") \ + #&& FileTest.file?("#{img_pth}/#{x}") + # FileUtils::cp("#{img_pth}/#{x}","#{@md.env.processing_path.epub}/#{Ep[:d_oebps]}/image") elsif FileTest.directory?("#{@md.env.processing_path.epub}/#{Ep[:d_oebps]}/image") \ && FileTest.file?("#{img_pth}/#{x}") FileUtils::cp("#{img_pth}/#{x}","#{@md.env.processing_path.epub}/#{Ep[:d_oebps]}/image") diff --git a/org/xml.org b/org/xml.org index 3b6e4085..d3736b85 100644 --- a/org/xml.org +++ b/org/xml.org @@ -3619,15 +3619,15 @@ module SiSU_XML_ODF_ODT @md.opt.act[:color_state][:set], "ERROR - image:", %{"#{i}" missing}, - "search locations: #{@env.path.image_source_include_local}," \ + "search locations: #{$sisu_base_data}/image," \ + "#{@env.path.image_source_include_remote} and" \ + "#{@env.path.image_source_include}" ).error2 unless @md.opt.act[:quiet][:set]==:on nil end elsif @md.fns =~/\.ss[tm]$/ \ - and FileTest.file?("#{@env.path.image_source_include_local}/#{i}") #review - @env.path.image_source_include_local + and FileTest.file?("#{$sisu_base_data}/image/#{i}") #review + $sisu_base_data + '/image' elsif @md.fns =~/\.ss[tm]$/ \ and FileTest.file?("#{@env.path.image_source_sisu_includes(@md)}/#{i}") @env.path.image_source_sisu_includes(@md) @@ -3640,7 +3640,7 @@ module SiSU_XML_ODF_ODT "ERROR - image:", %{"#{i}" missing}, "search locations: " \ - + @env.path.image_source_include_local + ',' \ + + $sisu_base_data + '/image' + ',' \ + @env.path.image_source_include_remote + 'and' \ + @env.path.image_source_include \ + @md.opt.sisu_data_dir? |