🐛 Small fixes to main install scripts

Add ask_for_sudo back to dot.sh; fix show_spinner & execute in utils.sh.
This commit is contained in:
Marley Rae 2024-01-22 21:02:43 -08:00
parent 8cc3e0afd2
commit 88c9b4f1b9
2 changed files with 6 additions and 3 deletions

View file

@ -290,7 +290,6 @@ restart_os()
printf "\n"
if answer_is_yes; then
ask_for_sudo
sudo shutdown -r now &> /dev/null
fi
}
@ -321,6 +320,10 @@ main()
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
ask_for_sudo
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
# Check if this script was run directly, and if not, dotfiles will need to be
# downloaded.

View file

@ -164,7 +164,7 @@ show_spinner()
tput sc
while kill -0 "$PID" &> /dev/null; do
frame_text=" [${FRAMES:i++%NUMBER_OF_FRAMES:1}] $MSG"
frame_text=" [${FRAMES:i++%NUMBER_OF_FRAMES:1}] $MSG"
# Print frame text.
printf "%s" "$frame_text"
@ -237,7 +237,7 @@ execute()
# Print output based on what happened.
print_result $exit_code "$MSG"
if [[ $exit -ne 0 ]]; then
if [[ $exit_code -ne 0 ]]; then
print_error_stream < "$TMP_FILE"
fi