minor bug fixes
This commit is contained in:
parent
4012541c5d
commit
ae08ff1cc0
1 changed files with 4 additions and 2 deletions
|
@ -16,6 +16,8 @@ declare -r ERASE_LINE=${CSI}$'2K'
|
|||
declare -r FRAME_OPEN=${CSI}$'2G['
|
||||
declare -r FRAME_CLOSE=${CSI}$'63G]'
|
||||
declare -r TS_POSITION=${CSI}$'65G'
|
||||
declare -r LINE_WRAP_OFF=${CSI}$'?7l'
|
||||
declare -r LINE_WRAP_ON=${CSI}$'?7h'
|
||||
declare -a RESET_LINE=${CURSOR_OFF}${ERASE_LINE}${FRAME_OPEN}${FRAME_CLOSE}
|
||||
|
||||
declare -a GRAPHIC_STR="| / - \\ + "
|
||||
|
@ -34,7 +36,7 @@ write_or_exit() {
|
|||
}
|
||||
|
||||
# initialize screen
|
||||
write_or_exit "${RESET_LINE}${TS_POSITION}0 min. 0 sec. "
|
||||
write_or_exit "${RESET_LINE}${TS_POSITION}0 min. 0 sec"
|
||||
|
||||
# loop forever..
|
||||
while true ; do
|
||||
|
@ -54,7 +56,7 @@ while true ; do
|
|||
(( PREV_SEC = SEC ))
|
||||
|
||||
# Display the accumulated time. div minutes.. modulo seconds.
|
||||
write_or_exit "${TS_POSITION}$(($SECONDS / 60)) min. $SEC sec. "
|
||||
write_or_exit "${TS_POSITION}$(($SECONDS / 60)) min. $SEC sec"
|
||||
done
|
||||
|
||||
exit
|
||||
|
|
Reference in a new issue