aboutsummaryrefslogtreecommitdiff
path: root/Tools
diff options
context:
space:
mode:
authorKris Kennaway <kris@FreeBSD.org>2003-10-13 02:54:56 +0000
committerKris Kennaway <kris@FreeBSD.org>2003-10-13 02:54:56 +0000
commitf1200b6ecca8b24a8f255a3b01ea82156ff1b8d8 (patch)
treef7b48de60580e3967bdac87ac80a4683bfe82d39 /Tools
parent6c56f2eb95c8513dffad1fcc9af6f643e8ca681f (diff)
downloadports-f1200b6ecca8b24a8f255a3b01ea82156ff1b8d8.tar.gz
ports-f1200b6ecca8b24a8f255a3b01ea82156ff1b8d8.zip
* Generate newfailure file (sorted list by original failure date) from failure
* Enhance HTML output to include both original and latest failure date, and number of times the build has failed.
Notes
Notes: svn path=/head/; revision=90974
Diffstat (limited to 'Tools')
-rwxr-xr-xTools/portbuild/scripts/processfail23
1 files changed, 13 insertions, 10 deletions
diff --git a/Tools/portbuild/scripts/processfail b/Tools/portbuild/scripts/processfail
index 67f77369e6a8..570afcb539c0 100755
--- a/Tools/portbuild/scripts/processfail
+++ b/Tools/portbuild/scripts/processfail
@@ -21,7 +21,7 @@ touch .newfailure.stamp
touch .failure.html.lock
newfailure=${pb}/${arch}/${branch}/newfailure
-num=$(wc -l ${newfailure})
+num=$(wc -l ${newfailure} | awk '{print $1}')
header() {
echo "<html><head><title>New package building errors</title>" >$of
@@ -44,25 +44,28 @@ footer() {
#
# Create "default" output, sorted on portname
#
-header "<th>Port</th><th>Package</th><th>Date broken</th>"
-
-for i in `cat ${newfailure}`; do
- set $(echo $i | tr ' ' '_' | tr \| " ")
+header "<th>Port</th><th>Package</th><th>Broken</th><th>Last</th><th>Count</th>"
+sort -r -n -k 4 -t \| failure > newfailure
+IFS='|'
+while read dir name ver date last count; do
echo "<tr>" >> $of
- echo "<td><a href=\"http://cvsweb.freebsd.org/ports/$1\">$1</a></td>" >> $of
- echo "<td><a href=\"${arch}-${branch}-latest/$3.log\">$3</a></td>" >> $of
+ echo "<td><a href=\"http://cvsweb.freebsd.org/ports/$dir\">$dir</a></td>" >> $of
+ echo "<td><a href=\"${arch}-${branch}-latest/$ver.log\">$ver</a></td>" >> $of
# echo "<td align=\"right\">$affby</td><td align=\"right\">$4 Kb</td>" >> $of
# echo "<td><a href=\"http://www.FreeBSD.org/cgi/cvsweb.cgi/ports/$5\">$5</a></td>" >> $of
# echo "<td><a href=\"mailto:$6\">$6</a></td>" >> $of
# echo "<td>" >> $of
- date=$(echo $4 | tr '_' ' ')
- echo "<td>${date}</td>" >> $of
+ alphadate=$(date -jf %s ${date})
+ alphalast=$(date -jf %s ${last})
+ echo "<td>${alphadate}</td>" >> $of
+ echo "<td>${alphalast}</td>" >> $of
+ echo "<td>$count</td>" >> $of
echo "</tr>" >> $of
-done
+done < newfailure
footer ""
rm .failure.html.lock
mv -f $of /usr/local/www/data/errorlogs/${arch}-${branch}-failure.html