summaryrefslogtreecommitdiffstats
path: root/bin
diff options
context:
space:
mode:
authorHolger Levsen <holger@layer-acht.org>2016-02-04 01:17:26 +0100
committerHolger Levsen <holger@layer-acht.org>2016-02-04 01:17:26 +0100
commit196e2d4ddb6441207bfbdedac527def09b6de609 (patch)
tree1ddbb32929caf6b0d1466acaff504c39621a341e /bin
parentefc01d180beabea3aede34411d879d0a450fff43 (diff)
downloadjenkins.debian.net-196e2d4ddb6441207bfbdedac527def09b6de609.tar.xz
reproducible debian: also show amount of packages build in the last 24h
Diffstat (limited to 'bin')
-rwxr-xr-xbin/reproducible_html_dashboard.sh11
1 files changed, 8 insertions, 3 deletions
diff --git a/bin/reproducible_html_dashboard.sh b/bin/reproducible_html_dashboard.sh
index c6dd2851..85dc7878 100755
--- a/bin/reproducible_html_dashboard.sh
+++ b/bin/reproducible_html_dashboard.sh
@@ -15,8 +15,8 @@ common_init "$@"
# init some variables
#
# we only do stats up until yesterday... we also could do today too but not update the db yet...
-DATE=$(date -d "1 day ago" '+%Y-%m-%d')
-FORCE_DATE=$(date -d "3 days ago" '+%Y-%m-%d')
+DATE=$(date -u -d "1 day ago" '+%Y-%m-%d')
+FORCE_DATE=$(date -u -d "3 days ago" '+%Y-%m-%d')
DUMMY_FILE=$(mktemp -t reproducible-dashboard-XXXXXXXX)
touch -d "$(date '+%Y-%m-%d') 00:00 UTC" $DUMMY_FILE
NOTES_GIT_PATH="/var/lib/jenkins/jobs/reproducible_html_notes/workspace"
@@ -327,7 +327,12 @@ write_build_performance_stats() {
RESULT="$(echo $RESULT/$TIMESPAN_RAW|bc)"
write_page "<td>$RESULT</td>"
done
-write_page "</tr></table>"
+ write_page "</tr><tr><td>packages tested in the last 24h</td>"
+ for ARCH in ${ARCHS} ; do
+ RESULT=$(sqlite3 -init ${INIT} ${PACKAGES_DB} "SELECT COUNT(r.build_date) FROM stats_build AS r WHERE r.build_date > datetime('$(date -u '+%Y-%m-%d')', '-24 hours') AND r.architecture='$ARCH'")
+ write_page "<td>$RESULT</td>"
+ done
+ write_page "</tr></table>"
}
#