X-Git-Url: http://gitweb.hugovil.com/?a=blobdiff_plain;f=functions%2Fmain;fp=functions%2Fmain;h=e90ce124a6e7b5f1a9d08a817fd7e0cb99e39fe2;hb=590b0ac584cf10c330b548f592437cb9099e8260;hp=246031492ef94cac1ccb78d5b8cf55066a1b17a8;hpb=f17ab848cb756cad27489bf0c2746e5ead466658;p=hvlinux.git diff --git a/functions/main b/functions/main index 2460314..e90ce12 100644 --- a/functions/main +++ b/functions/main @@ -1146,15 +1146,15 @@ get_total_build_time() for time in ${TIMES}; do HOURS=$(( $HOURS + $(echo ${time} | sed "s!^\([0-9]*\)\..*!\1!g") )) - + # The first SED command extracts the minutes (fractions of an hour). # The second SED command removed the leading zero, if applicable. MIN=$(( $MIN + $(echo ${time} | sed "s!.*\.\([0-9][0-9]\)!\1!g" | sed "s!^0\([0-9]\)!\1!g" ) )) done - + HOURS=$(( ${HOURS} + ( ${MIN} / 100 ) )) MIN=$(( ${MIN} % 100 )) - + echo "${HOURS}.${MIN}" }