mirror of
https://github.com/community-scripts/ProxmoxVE
synced 2025-02-11 02:09:17 +00:00
Prevent double spinner
This commit is contained in:
parent
f94d727af7
commit
74d914bb5b
@ -64,6 +64,7 @@ function spinner() {
|
|||||||
|
|
||||||
# This function displays an informational message with a yellow color.
|
# This function displays an informational message with a yellow color.
|
||||||
function msg_info() {
|
function msg_info() {
|
||||||
|
if [ -n "$SPINNER_PID" ] && ps -p $SPINNER_PID > /dev/null; then kill $SPINNER_PID > /dev/null; fi
|
||||||
local msg="$1"
|
local msg="$1"
|
||||||
echo -ne "${TAB}${YW}${HOLD}${msg}${HOLD}"
|
echo -ne "${TAB}${YW}${HOLD}${msg}${HOLD}"
|
||||||
spinner &
|
spinner &
|
||||||
|
@ -98,6 +98,7 @@ spinner() {
|
|||||||
|
|
||||||
# This function displays an informational message with a yellow color.
|
# This function displays an informational message with a yellow color.
|
||||||
msg_info() {
|
msg_info() {
|
||||||
|
if [ -n "$SPINNER_PID" ] && ps -p $SPINNER_PID > /dev/null; then kill $SPINNER_PID > /dev/null; fi
|
||||||
local msg="$1"
|
local msg="$1"
|
||||||
echo -ne "${TAB}${YW}${HOLD}${msg}${HOLD}"
|
echo -ne "${TAB}${YW}${HOLD}${msg}${HOLD}"
|
||||||
spinner &
|
spinner &
|
||||||
|
@ -90,6 +90,7 @@ spinner() {
|
|||||||
|
|
||||||
# This function displays an informational message with a yellow color.
|
# This function displays an informational message with a yellow color.
|
||||||
msg_info() {
|
msg_info() {
|
||||||
|
if [ -n "$SPINNER_PID" ] && ps -p $SPINNER_PID > /dev/null; then kill $SPINNER_PID > /dev/null; fi
|
||||||
local msg="$1"
|
local msg="$1"
|
||||||
echo -ne "${TAB}${YW}${HOLD}${msg}${HOLD}"
|
echo -ne "${TAB}${YW}${HOLD}${msg}${HOLD}"
|
||||||
spinner &
|
spinner &
|
||||||
|
Loading…
Reference in New Issue
Block a user