scripts/functions
changeset 141 860f8380538d
parent 136 22b5ef41df97
child 145 1761c8b3f415
     1.1 --- a/scripts/functions	Sun May 27 20:22:06 2007 +0000
     1.2 +++ b/scripts/functions	Mon May 28 20:57:40 2007 +0000
     1.3 @@ -67,8 +67,7 @@
     1.4          cat -
     1.5      else
     1.6          echo "${1}"
     1.7 -    fi |( offset=$((`CT_DoDate +%s`+(CT_STAR_DATE/(1000*1000*1000))))
     1.8 -          IFS="\n" # We want the full lines, even leading spaces
     1.9 +    fi |( IFS="\n" # We want the full lines, even leading spaces
    1.10            CT_PROG_BAR_CPT=0
    1.11            indent=$((2*CT_STEP_COUNT))
    1.12            while read line; do
    1.13 @@ -86,12 +85,11 @@
    1.14                    echo -e "\r${l}" >&6
    1.15                fi
    1.16                if [ "${CT_LOG_PROGRESS_BAR}" = "y" ]; then
    1.17 -                  elapsed=$((SECONDS+OFFSET))
    1.18                    [ ${CT_PROG_BAR_CPT} -eq 0  ] && bar="/"
    1.19                    [ ${CT_PROG_BAR_CPT} -eq 10 ] && bar="-"
    1.20                    [ ${CT_PROG_BAR_CPT} -eq 20 ] && bar="\\"
    1.21                    [ ${CT_PROG_BAR_CPT} -eq 30 ] && bar="|"
    1.22 -                  printf "\r[%02d:%02d] %s " $((elapsed/60)) $((elapsed%60)) "${bar}" >&6
    1.23 +                  printf "\r[%02d:%02d] %s " $((SECONDS/60)) $((SECONDS%60)) "${bar}" >&6
    1.24                    CT_PROG_BAR_CPT=$(((CT_PROG_BAR_CPT+1)%40))
    1.25                fi
    1.26            done
    1.27 @@ -548,6 +546,8 @@
    1.28      local old_RESTART="${CT_RESTART}"
    1.29      local old_STOP="${CT_STOP}"
    1.30  
    1.31 +    CT_TestOrAbort "The previous build did not reach the point where it could be restarted at \"${CT_RESTART}\"" -d "${state_dir}"
    1.32 +
    1.33      # We need to do something special with the log file!
    1.34      if [ "${CT_LOG_TO_FILE}" = "y" ]; then
    1.35          exec >"${state_dir}/tail.log"