mirror of
https://gitlab.archlinux.org/tpowa/archboot.git
synced 2024-09-21 20:40:38 +02:00
replace true with real check
This commit is contained in:
parent
add813b616
commit
dc08b4af9d
2 changed files with 2 additions and 2 deletions
|
@ -30,7 +30,7 @@ _clear() {
|
||||||
# $1: start percentage $2: end percentage $3: message $4: sleep time
|
# $1: start percentage $2: end percentage $3: message $4: sleep time
|
||||||
_progress_wait() {
|
_progress_wait() {
|
||||||
_COUNT=${1}
|
_COUNT=${1}
|
||||||
while true; do
|
while [[ -e /.archboot ]]; do
|
||||||
if [[ "${_COUNT}" -lt "${2}" ]]; then
|
if [[ "${_COUNT}" -lt "${2}" ]]; then
|
||||||
_progress "${_COUNT}" "${3}"
|
_progress "${_COUNT}" "${3}"
|
||||||
fi
|
fi
|
||||||
|
@ -39,7 +39,6 @@ _progress_wait() {
|
||||||
fi
|
fi
|
||||||
_COUNT="$((_COUNT+1))"
|
_COUNT="$((_COUNT+1))"
|
||||||
sleep "${4}"
|
sleep "${4}"
|
||||||
! [[ -e /.archboot ]] && break
|
|
||||||
done
|
done
|
||||||
}
|
}
|
||||||
_task() {
|
_task() {
|
||||||
|
|
|
@ -55,6 +55,7 @@ if [[ "${TTY}" = "tty1" ]]; then
|
||||||
: > /.archboot
|
: > /.archboot
|
||||||
_create_btrfs &
|
_create_btrfs &
|
||||||
_progress_wait "0" "10" "Creating btrfs on /dev/zram0..." "0.2"
|
_progress_wait "0" "10" "Creating btrfs on /dev/zram0..." "0.2"
|
||||||
|
# avoid clipping, insert status message
|
||||||
_progress "10" "Creating btrfs on /dev/zram0..."
|
_progress "10" "Creating btrfs on /dev/zram0..."
|
||||||
: > /.archboot
|
: > /.archboot
|
||||||
_copy_root &
|
_copy_root &
|
||||||
|
|
Loading…
Reference in a new issue