diff options
author | Ralph Amissah <ralph@amissah.com> | 2012-02-14 21:44:59 -0500 |
---|---|---|
committer | Ralph Amissah <ralph@amissah.com> | 2012-02-14 21:44:59 -0500 |
commit | dc9c326e4a90ba9019cdcde75176eac7990a269f (patch) | |
tree | a5f38e98c512456192fbe06d1bf62d19b3fe567a /lib/sisu/v3dv/html.rb | |
parent | debian/changelog (3.1.13-1) (diff) | |
parent | v3dv: control hooks (diff) |
Merge tag 'sisu_3.1.14' into debian/sid
Diffstat (limited to 'lib/sisu/v3dv/html.rb')
-rw-r--r-- | lib/sisu/v3dv/html.rb | 27 |
1 files changed, 13 insertions, 14 deletions
diff --git a/lib/sisu/v3dv/html.rb b/lib/sisu/v3dv/html.rb index ec7b0573..75d89382 100644 --- a/lib/sisu/v3dv/html.rb +++ b/lib/sisu/v3dv/html.rb @@ -138,14 +138,10 @@ module SiSU_HTML def link_images @symlnk.images end - def directories - title=File.basename(@md.fns,'.rb') - end def tuned_file_instructions @tell=SiSU_Screen::Ansi.new(@md.opt.cmd) @md.opt.cmd=@md.opt.cmd.gsub(/H/,'h') - @md.file_type='html' if @md.opt.cmd =~/[hon]/ - directories + @md.file_type='html' if @md.opt.cmd =~/[hw]/ newfilename=%{#{@md.file.output_path.html_scroll.dir}/#{@md.file.base_filename.html_segtoc}} if @md.file_type =~/html/ dal_array=@particulars.dal_array # dal file drawn here @tuned_file_array=SiSU_HTML_Tune::Tune.new(dal_array,@md).songsheet @@ -611,7 +607,8 @@ WOK class Output def initialize(data='',md='') @data,@md=data,md - @file=SiSU_Env::FileOp.new(@md) + @file=SiSU_Env::FileOp.new(md) + @o_str ||=SiSU_Env::OutputStructure.new(md).output_dir_structure end def scroll begin @@ -646,15 +643,17 @@ WOK rescue; SiSU_Errors::InfoError.new($!,$@,@md.opt.cmd,@md.fns).error ensure @filename_html_segtoc.close - unless FileTest.file?("#{@file.output_path.html_seg.dir}/#{@md.file.base_filename.html_seg_index}") - pwd_set=Dir.pwd - idx_lnk=@file.base_filename.html_segtoc - mlnk=@file.base_filename.html_seg_index - Dir.chdir(@file.output_path.html_seg.dir) - FileUtils::rm_f(mlnk) - FileUtils::ln_s(idx_lnk, mlnk) - Dir.chdir(pwd_set) + pwd_set=Dir.pwd + idx_lnk=if @o_str.dump_or_redirect? + @file.base_filename.manifest + else + @file.base_filename.html_segtoc end + mlnk=@file.base_filename.html_seg_index + Dir.chdir(@file.output_path.html_seg.dir) + FileUtils::rm_f(mlnk) + FileUtils::ln_s(idx_lnk,mlnk) + Dir.chdir(pwd_set) end end end |