From c814efbf988a0da667ebc90c5f1b2325c7014cfe Mon Sep 17 00:00:00 2001
From: Holger Levsen
Date: Mon, 2 Mar 2015 22:52:48 +0100
Subject: reproducible: yet more multi-suite fixes
---
bin/reproducible_html_graphs.sh | 27 ++++++++++++++++-----------
1 file changed, 16 insertions(+), 11 deletions(-)
(limited to 'bin/reproducible_html_graphs.sh')
diff --git a/bin/reproducible_html_graphs.sh b/bin/reproducible_html_graphs.sh
index e36ae9c0..5555ca53 100755
--- a/bin/reproducible_html_graphs.sh
+++ b/bin/reproducible_html_graphs.sh
@@ -69,6 +69,8 @@ if [ -z $RESULT ] ; then
# we do 3 later and 6 is special anyway...
for i in 0 1 2 4 5 ; do
# force regeneration of the image if it exists
+ # FIXME: 0 needs $SUITE
+ # FIXME: some other queries above need *not* to refer to $SUITE... but rather $SUITES
[ ! -f ${TABLE[$i]}.png ] || touch -d "$DATE 00:00" ${TABLE[$i]}.png
done
fi
@@ -139,7 +141,7 @@ if [ "$SUITE" != "experimental" ] ; then
META_RESULT=true
gather_meta_stats $i
! $META_RESULT || sqlite3 -init ${INIT} ${PACKAGES_DB} "INSERT INTO ${TABLE[6]} VALUES (\"$DATE\", \"$SUITE\", \"${META_PKGSET[$i]}\", $COUNT_META_GOOD, $COUNT_META_BAD, $COUNT_META_UGLY, $COUNT_META_REST)"
- touch -d "$DATE 00:00" ${TABLE[6]}_${META_PKGSET[$i]}.png
+ touch -d "$DATE 00:00" $SUITE/${TABLE[6]}_${META_PKGSET[$i]}.png
fi
done
fi
@@ -170,7 +172,7 @@ if [ -z $RESULT ] ; then
echo $SQL
sqlite3 -init ${INIT} ${PACKAGES_DB} "$SQL"
# force regeneration of the image
- touch -d "$DATE 00:00" ${TABLE[3]}.png
+ touch -d "$DATE 00:00" $SUITE/${TABLE[3]}.png
fi
# used for redo_png (but only needed to define once)
@@ -284,10 +286,10 @@ set_icon blacklisted
write_icon
write_page "$COUNT_BLACKLISTED blacklisted packages neither.
"
write_page ""
-write_page " "
+write_page " "
# redo png once a day
if [ ! -f /var/lib/jenkins/userContent/$SUITE/${TABLE[0]}.png ] || [ -z $(find /var/lib/jenkins/userContent/$SUITE -maxdepth 1 -mtime +0 -name ${TABLE[0]}.png) ] ; then
- redo_png 0 ${TABLE[0]}.png
+ redo_png 0 $SUITE/${TABLE[0]}.png
fi
write_page "
"
write_page_footer
@@ -303,7 +305,7 @@ echo "$(date) - starting to write $PAGE page."
write_page_header $VIEW "Overview about reproducible builds of specific package sets in $SUITE"
write_page "- Tracked package sets:
"
for i in $(seq 1 ${#META_PKGSET[@]}) ; do
- if [ -f /var/lib/jenkins/userContent/${TABLE[6]}_${META_PKGSET[$i]}.png ] ; then
+ if [ -f /var/lib/jenkins/userContent/$SUITE/${TABLE[6]}_${META_PKGSET[$i]}.png ] ; then
write_page "- ${META_PKGSET[$i]}
"
fi
done
@@ -317,10 +319,10 @@ for i in $(seq 1 ${#META_PKGSET[@]}) ; do
YLABEL[6]="Amount (${META_PKGSET[$i]} packages)"
PNG=${TABLE[6]}_${META_PKGSET[$i]}.png
# redo pngs once a day
- if [ ! -f /var/lib/jenkins/userContent/$PNG ] || [ -z $(find /var/lib/jenkins/userContent -maxdepth 1 -mtime +0 -name $PNG) ] ; then
- redo_png 6 $PNG ${META_PKGSET[$i]}
+ if [ ! -f /var/lib/jenkins/userContent/$SUITE/$PNG ] || [ -z $(find /var/lib/jenkins/userContent/$SUITE -maxdepth 1 -mtime +0 -name $PNG) ] ; then
+ redo_png 6 $SUITE/$PNG ${META_PKGSET[$i]}
fi
- write_page ""
+ write_page "
"
write_page "
The package set '${META_PKGSET[$i]}' consists of:
"
set_icon reproducible
write_icon
@@ -369,14 +371,17 @@ VIEW=stats
PAGE=index_${VIEW}.html
echo "$(date) - starting to write $PAGE page."
write_page_header $VIEW "Overview of various statistics about reproducible builds"
-write_page "
"
-write_page "
"
+write_page "
"
+for $i in $SUITES ; do
+ write_page " | "
+done
+write_page "
"
# FIXME: we don't do 2 / stats_builds_age.png yet :/ (and 6 and 0 are done already)
for i in 3 4 5 1 ; do
if [ "$i" = "3" ] ; then
write_usertag_table
fi
- write_page " "
+ write_page " "
# redo pngs once a day
if [ ! -f /var/lib/jenkins/userContent/${TABLE[$i]}.png ] || [ -z $(find /var/lib/jenkins/userContent -maxdepth 1 -mtime +0 -name ${TABLE[$i]}.png) ] ; then
redo_png $i ${TABLE[$i]}.png
--
cgit v1.2.3-70-g09d2