From 38c9949dd700b79e8e288107228dfc0fe8be2db4 Mon Sep 17 00:00:00 2001 From: Vincent Riquer Date: Sun, 1 Feb 2015 04:30:51 +0100 Subject: [PATCH] add timing information --- index | 20 +++++++++++++++++--- 1 file changed, 17 insertions(+), 3 deletions(-) diff --git a/index b/index index eefc4cb..97b8e2b 100755 --- a/index +++ b/index @@ -60,8 +60,7 @@ then -d @$(rrdtool last ingress.rrd) ) Expires: $(LC_ALL=C TZ=GMT date +'%a, %d %b %Y %X %Z' -d '1 hour') - Cache-Control: max-age=0, must-revalidate - refresh: 600 + refresh: 10 +
+ EOHTML + times + date '+%Y-%m-%d %H:%M:%S' + cat <<-EOHTML +
EOHTML @@ -137,6 +142,7 @@ then for level in {1..16} do + prevtimestamp=$maxtimestamp never=0 maxtimestamp=0 tableline=() @@ -297,11 +303,14 @@ then echo "${tableline[@]}" if (( level > curlevel )) then + (( maxtimestamp < prevtimestamp )) \ + && maxtimestamp=$prevtimestamp cat <<-EOHTML $(date +%Y-%m-%d -d @$maxtimestamp) EOHTML fi echo '' + prevtimestamp=$maxtimestamp done cat <<-EOHTML @@ -461,6 +470,12 @@ then
+
+ EOHTML + times + date '+%Y-%m-%d %H:%M:%S' + cat <<-EOHTML +
EOHTML else @@ -472,7 +487,6 @@ else -d @$(rrdtool last ingress.rrd) ) Expires: $(LC_ALL=C TZ=GMT date +'%a, %d %b %Y %X %Z' -d '1 hour') - Cache-Control: max-age=0, must-revalidate EOHEAD