Skip to content

Commit

Permalink
fix: do not cover console output with msgbox
Browse files Browse the repository at this point in the history
Signed-off-by: ZHANG Yuntian <[email protected]>
  • Loading branch information
RadxaYuntian committed Aug 7, 2024
1 parent c337db5 commit 7a23654
Showing 1 changed file with 9 additions and 16 deletions.
25 changes: 9 additions & 16 deletions src/usr/lib/rsetup/tui/system/system.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,22 +3,15 @@
__system_system_update() {
if yesno "System will be updated, continue?"
then
local ret=0
system_update || ret=$?
case "$ret" in
1)
msgbox "Unable to update package list." "$RTUI_PALETTE_ERROR"
;;
2)
msgbox "Unable to upgrade packages." "$RTUI_PALETTE_ERROR"
;;
3)
msgbox "Unable to upgrade pinned packages." "$RTUI_PALETTE_ERROR"
;;
*)
msgbox "Unknown error." "$RTUI_PALETTE_ERROR"
;;
esac
if ! system_update; then
cat <<EOF
==================
Update has failed.
This may be caused by network issue, or clock out of sync.
You can try update again later.
EOF
fi
read -rp "Press enter to continue..."
fi
}

Expand Down

0 comments on commit 7a23654

Please sign in to comment.