[Qa-jenkins-scm] [jenkins.debian.net] 02/03: reproducible: make titles work properly also for global pages

Holger Levsen holger at moszumanska.debian.org
Thu Mar 5 16:54:04 UTC 2015


This is an automated email from the git hooks/post-receive script.

holger pushed a commit to branch master
in repository jenkins.debian.net.

commit e71c017135a3ea08ad7b989845f7065ed277122a
Author: Holger Levsen <holger at layer-acht.org>
Date:   Thu Mar 5 17:04:53 2015 +0100

    reproducible: make titles work properly also for global pages
---
 bin/reproducible_html_indexes.py | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/bin/reproducible_html_indexes.py b/bin/reproducible_html_indexes.py
index 04e2101..a677592 100755
--- a/bin/reproducible_html_indexes.py
+++ b/bin/reproducible_html_indexes.py
@@ -327,10 +327,12 @@ def build_page(page, suite=None, arch=None):
     if not suite:  # global page
         log.info('Building the ' + page + ' global index page...')
         page_sections = global_pages[page]['body']
+        title = global_pages[page]['title']
     else:
         log.info('Building the ' + page + ' index page for ' + suite + '/' +
                  arch + '...')
         page_sections = pages[page]['body']
+        title = pages[page]['title']
     html = ''
     footnote = False
     for section in page_sections:
@@ -343,10 +345,6 @@ def build_page(page, suite=None, arch=None):
             html1, footnote1 = build_page_section(page, section, suite, arch)
             html += html1
             footnote = True if footnote1 else footnote
-    try:
-        title = pages[page]['title']
-    except KeyError:
-        title = page
     if not suite:  # global page
         destfile = BASE + '/index_' + page + '.html'
         desturl = REPRODUCIBLE_URL + '/index_' + page + '.html'

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/qa/jenkins.debian.net.git



More information about the Qa-jenkins-scm mailing list