diff options
| -rwxr-xr-x | bin/sisu | 2 | ||||
| -rw-r--r-- | lib/sisu/se_createsite.rb | 2 | ||||
| -rw-r--r-- | lib/sisu/xhtml_epub2.rb | 8 | ||||
| -rw-r--r-- | lib/sisu/xml_odf_odt.rb | 8 | ||||
| -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 | 
8 files changed, 30 insertions, 10 deletions
| @@ -296,6 +296,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/lib/sisu/se_createsite.rb b/lib/sisu/se_createsite.rb index 4d5a1dec..f998f43d 100644 --- a/lib/sisu/se_createsite.rb +++ b/lib/sisu/se_createsite.rb @@ -159,7 +159,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/lib/sisu/xhtml_epub2.rb b/lib/sisu/xhtml_epub2.rb index 63ac620f..8f6ef05a 100644 --- a/lib/sisu/xhtml_epub2.rb +++ b/lib/sisu/xhtml_epub2.rb @@ -786,6 +786,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 @@ -797,6 +802,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/lib/sisu/xml_odf_odt.rb b/lib/sisu/xml_odf_odt.rb index 75537204..fb9c9cde 100644 --- a/lib/sisu/xml_odf_odt.rb +++ b/lib/sisu/xml_odf_odt.rb @@ -256,15 +256,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) @@ -277,7 +277,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? 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? | 
