cookutils rev 884
cook.conf: add SETUP_MD5 value
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Wed Feb 22 19:00:35 2017 +0100 (2017-02-22) |
parents | 30ca1ab8368a |
children | 86a8c2d50361 |
files | cook.conf web/cooker.cgi |
line diff
1.1 --- a/cook.conf Wed Feb 22 13:34:35 2017 +0100 1.2 +++ b/cook.conf Wed Feb 22 19:00:35 2017 +0100 1.3 @@ -17,6 +17,9 @@ 1.4 DB="/var/lib/tazpkg" 1.5 INSTALLED="$DB/installed" 1.6 1.7 +# Result of "ls $INSTALLED | md5sum | cut -c1-32" 1.8 +SETUP_MD5="" 1.9 + 1.10 # Quality Assurance (empty to disable receipt_quality). 1.11 QA="0" 1.12
2.1 --- a/web/cooker.cgi Wed Feb 22 13:34:35 2017 +0100 2.2 +++ b/web/cooker.cgi Wed Feb 22 19:00:35 2017 +0100 2.3 @@ -253,7 +253,7 @@ 2.4 if [ -s "$command" ]; then 2.5 state="$(cat $command)" 2.6 set -- $(grep "^$state" $cooktime) 2.7 - if [ -n "$1" ]; then 2.8 + if [ -n "$1" -a $2 -ne 0 ]; then 2.9 state="$state $((($(date +%s)-$3)*100/$2))%" 2.10 [ $2 -gt 300 ] && state="$state (should end $(date -u -d @$(($2+$3))))" 2.11 fi