From 9639fdd4594cfd8e0d65058ecd8e41775f0114c7 Mon Sep 17 00:00:00 2001 From: Mattia Rizzolo Date: Wed, 18 Feb 2015 01:39:37 +0100 Subject: reproducible: html_all_packages: quick rewrite of this tiny script in python + add support for multi release --- bin/reproducible_html_all_packages.py | 19 +++++++++++++++++++ bin/reproducible_html_all_packages.sh | 25 ------------------------- job-cfg/reproducible.yaml | 2 +- 3 files changed, 20 insertions(+), 26 deletions(-) create mode 100755 bin/reproducible_html_all_packages.py delete mode 100755 bin/reproducible_html_all_packages.sh diff --git a/bin/reproducible_html_all_packages.py b/bin/reproducible_html_all_packages.py new file mode 100755 index 00000000..eafe5d4a --- /dev/null +++ b/bin/reproducible_html_all_packages.py @@ -0,0 +1,19 @@ +#!/usr/bin/python3 +# -*- coding: utf-8 -*- +# +# Copyright © 2015 Mattia Rizzolo +#Based on reproducible_html_all_packages.sh © 2014 Holger Levsen +# Licensed under GPL-2 +# +# Depends: python3 +# +# Build all rb-pkg pages (the pages that describe the package status) using +# code already written in reproducible_html_packages + + +from reproducible_common import * +from reproducible_html_packages import gen_all_rb_pkg_pages + + +for suite in SUITES: + gen_all_rb_pkg_pages(suite=suite) diff --git a/bin/reproducible_html_all_packages.sh b/bin/reproducible_html_all_packages.sh deleted file mode 100755 index 7563d423..00000000 --- a/bin/reproducible_html_all_packages.sh +++ /dev/null @@ -1,25 +0,0 @@ -#!/bin/bash - -# Copyright 2014 Holger Levsen -# released under the GPLv=2 - -DEBUG=false -. /srv/jenkins/bin/common-functions.sh -common_init "$@" - -# common code defining db access -. /srv/jenkins/bin/reproducible_common.sh - -set +x -init_html - -# -# attempt to rebuild all package pages -# (will only happen if they don't exist or are older than build date.) -# (should never be needed) -# -PACKAGES=$(sqlite3 -init $INIT $PACKAGES_DB "SELECT name FROM source_packages WHERE status != \"\"") -COUNT_TOTAL=$(sqlite3 -init $INIT $PACKAGES_DB "SELECT COUNT(name) FROM source_packages WHERE status != \"\"") -echo "$(date) - processing $COUNT_TOTAL packages... this will take a while." -gen_packages_html ${PACKAGES} - diff --git a/job-cfg/reproducible.yaml b/job-cfg/reproducible.yaml index bfe1f7c7..bcdf71f8 100644 --- a/job-cfg/reproducible.yaml +++ b/job-cfg/reproducible.yaml @@ -233,7 +233,7 @@ - '{name}_html_all_packages': my_description: 'Generate HTML results (for all packages) for reproducible builds. This job is normally not needed and only run once a year.' my_timed: '12 12 30 12 *' - my_shell: '/srv/jenkins/bin/reproducible_html_all_packages.sh' + my_shell: '/srv/jenkins/bin/reproducible_html_all_packages.py' my_recipients: 'holger@layer-acht.org' - '{name}_html_repo_stats': my_description: 'Generate HTML results (repo_stats) for reproducible builds.' -- cgit v1.2.3-54-g00ecf