diff options
author | Ralph Amissah <ralph@amissah.com> | 2012-12-28 12:41:38 -0500 |
---|---|---|
committer | Ralph Amissah <ralph@amissah.com> | 2012-12-28 12:41:38 -0500 |
commit | 577f1efec130fd159116cf156fbaf76ede3aecc8 (patch) | |
tree | 4c6239ad640c84efdda411377557f4c3ae0a2c60 | |
parent | v4: bin/sisu sysenv, rc_path_options, provide fixed path to rc files (diff) |
v4 v3: html_segments (by_filename by_filetype) broken internal doc links fixed
* filenames need to include lang code
* [chals on irc, re live-manual, debian-live]
-rw-r--r-- | data/doc/sisu/CHANGELOG_v3 | 4 | ||||
-rw-r--r-- | data/doc/sisu/CHANGELOG_v4 | 4 | ||||
-rw-r--r-- | lib/sisu/v3/html_segments.rb | 6 | ||||
-rw-r--r-- | lib/sisu/v4/html_segments.rb | 6 |
4 files changed, 18 insertions, 2 deletions
diff --git a/data/doc/sisu/CHANGELOG_v3 b/data/doc/sisu/CHANGELOG_v3 index 654ddb4c..134b6bfe 100644 --- a/data/doc/sisu/CHANGELOG_v3 +++ b/data/doc/sisu/CHANGELOG_v3 @@ -36,6 +36,10 @@ http://www.jus.uio.no/sisu/pkg/src/sisu_3.3.4.orig.tar.xz sisu_3.3.4-1.dsc sisu_3.3.4-1.debian.tar.gz +* v3: html_segments (by_filename by_filetype) internal document links do not + work filenames need to include lang code, fixed + [chals on irc, re live-manual, debian-live] + * v3: debug (internal code use), color markers for line number & file name (colored location markers to show when line passed within running code) diff --git a/data/doc/sisu/CHANGELOG_v4 b/data/doc/sisu/CHANGELOG_v4 index 0613f2ac..326c56bc 100644 --- a/data/doc/sisu/CHANGELOG_v4 +++ b/data/doc/sisu/CHANGELOG_v4 @@ -25,6 +25,10 @@ http://www.jus.uio.no/sisu/pkg/src/sisu_4.0.1.orig.tar.xz sisu_4.0.1-1.dsc sisu_4.0.1-1.debian.tar.gz +* v4: html_segments (by_filename by_filetype) internal document links do not + work filenames need to include lang code, fixed + [chals on irc, re live-manual, debian-live] + * v4: bin/sisu & sysenv, rc_path_options, provide fixed path to rc files, (used e.g. to load sisurc.yml) diff --git a/lib/sisu/v3/html_segments.rb b/lib/sisu/v3/html_segments.rb index 81bb08d4..a5364467 100644 --- a/lib/sisu/v3/html_segments.rb +++ b/lib/sisu/v3/html_segments.rb @@ -211,7 +211,11 @@ module SiSU_HTML_Seg m=$1 if map_nametags[m] \ and map_nametags[m][:segname] - dob.obj.sub!(/href="#{Xx[:segment]}#+(\S+?)"/,%{href="#{map_nametags[m][:segname]}#{Sfx[:html]}#\\1"}) + inf=SiSU_Env::FileOp.new(@md) if @md + lng=(inf.output_dir_structure.by_language_code?) \ + ? '' + : '.' + @md.opt.lng + dob.obj.sub!(/href="#{Xx[:segment]}#+(\S+?)"/,%{href="#{map_nametags[m][:segname]}#{lng}#{Sfx[:html]}#\\1"}) else p "NOT FOUND name_tags: #{m}" dob.obj.sub!(/href="#{Xx[:segment]}#+(\S+?)"/,%{href="#\\1"}) # not satisfactory diff --git a/lib/sisu/v4/html_segments.rb b/lib/sisu/v4/html_segments.rb index 97334023..d83e7d5f 100644 --- a/lib/sisu/v4/html_segments.rb +++ b/lib/sisu/v4/html_segments.rb @@ -211,7 +211,11 @@ module SiSU_HTML_Seg m=$1 if map_nametags[m] \ and map_nametags[m][:segname] - dob.obj.sub!(/href="#{Xx[:segment]}#+(\S+?)"/,%{href="#{map_nametags[m][:segname]}#{Sfx[:html]}#\\1"}) + inf=SiSU_Env::FileOp.new(@md) if @md + lng=(inf.output_dir_structure.by_language_code?) \ + ? '' + : '.' + @md.opt.lng + dob.obj.sub!(/href="#{Xx[:segment]}#+(\S+?)"/,%{href="#{map_nametags[m][:segname]}#{lng}#{Sfx[:html]}#\\1"}) else p "NOT FOUND name_tags: #{m}" dob.obj.sub!(/href="#{Xx[:segment]}#+(\S+?)"/,%{href="#\\1"}) # not satisfactory |