From c5865a49f03b0a7c796d662baa42930f6e14aaef Mon Sep 17 00:00:00 2001 From: Joe Cooper Date: Sat, 19 Aug 2017 15:49:16 -0500 Subject: [PATCH] reset cursor whenever exiting from spin --- slib.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/slib.sh b/slib.sh index e0ce6fb..a3f9485 100644 --- a/slib.sh +++ b/slib.sh @@ -14,6 +14,8 @@ cleanup () { if [ ! -z "$allpids" ]; then for pid in $allpids; do kill "$pid" 1>/dev/null 2>&1 + tput rc + tput cnorm done fi } @@ -255,6 +257,7 @@ spinner () { fi done done + tput rc tput cnorm return 0 } @@ -327,6 +330,7 @@ run_ok () { echo "Made it here...why?" >> ${RUN_LOG} kill $spinpid 2>/dev/null rm -rf ${SPINNER_DONEFILE} 2>/dev/null 2>&1 + tput rc tput cnorm fi # Log what we were supposed to be running