replace true with real check

This commit is contained in:
Tobias Powalowski 2023-11-17 20:00:29 +01:00
parent add813b616
commit dc08b4af9d
2 changed files with 2 additions and 2 deletions

View file

@ -30,7 +30,7 @@ _clear() {
# $1: start percentage $2: end percentage $3: message $4: sleep time
_progress_wait() {
_COUNT=${1}
while true; do
while [[ -e /.archboot ]]; do
if [[ "${_COUNT}" -lt "${2}" ]]; then
_progress "${_COUNT}" "${3}"
fi
@ -39,7 +39,6 @@ _progress_wait() {
fi
_COUNT="$((_COUNT+1))"
sleep "${4}"
! [[ -e /.archboot ]] && break
done
}
_task() {

View file

@ -55,6 +55,7 @@ if [[ "${TTY}" = "tty1" ]]; then
: > /.archboot
_create_btrfs &
_progress_wait "0" "10" "Creating btrfs on /dev/zram0..." "0.2"
# avoid clipping, insert status message
_progress "10" "Creating btrfs on /dev/zram0..."
: > /.archboot
_copy_root &