From 0875691dfc19bc44c8ddef66c0b8b55547f62dce Mon Sep 17 00:00:00 2001 From: William Melody Date: Sat, 2 Sep 2023 12:21:13 -0700 Subject: [PATCH] Improve `_spinner()` behavior. refs gh-269 --- nb | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/nb b/nb index 7caa46bba..064d318e2 100755 --- a/nb +++ b/nb @@ -3299,7 +3299,7 @@ _spinner() { "${_TPUT_SETAF_8}" \ "${_TPUT_SGR0}" - printf "\b\b\b\b\b\b\b\b" + printf "\b\b\b\b" fi sleep ${_delay} @@ -3307,11 +3307,6 @@ _spinner() { _spin_string="${_temp}${_spin_string%"${_temp}"}" done - if ((_COLOR_ENABLED)) - then - printf " \b\b\b\b\b\b\b\b" - fi - return 0 } @@ -3680,7 +3675,7 @@ _git() { if ((NB_AUTO_SYNC)) then - ( + ( sleep 2 { # only commit when the index is dirty if _git dirty "${_notebook_path}" @@ -3690,7 +3685,7 @@ _git() { } || : ) & else - ( + ( sleep 2 _git_checkpoint_commit "${_notebook_path}" "${_message}" &>/dev/null || return 0 ) &