mirror of
https://github.com/raspiblitz/raspiblitz.git
synced 2025-10-11 05:13:13 +02:00
added finish condition
This commit is contained in:
@@ -57,18 +57,15 @@ while [ ${finished} -eq 0 ]
|
|||||||
progress=$(echo "${blockchaininfo}" | jq -r '.verificationprogress')
|
progress=$(echo "${blockchaininfo}" | jq -r '.verificationprogress')
|
||||||
#progress=$(echo "${progress}*100" | bc)
|
#progress=$(echo "${progress}*100" | bc)
|
||||||
inprogress="$(echo "${blockchaininfo}" | jq -r '.initialblockdownload')"
|
inprogress="$(echo "${blockchaininfo}" | jq -r '.initialblockdownload')"
|
||||||
if [ "${inprogress}" = "true" ]; then
|
if [ "${inprogress}" = "false" ]; then
|
||||||
finished=1
|
finished=1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo ""
|
echo ""
|
||||||
|
echo "RUNNING: ${inprogress}"
|
||||||
echo "PROGRESS: ${progress}"
|
echo "PROGRESS: ${progress}"
|
||||||
echo "running: ${inprogress}"
|
|
||||||
echo ""
|
echo ""
|
||||||
|
|
||||||
#TODO: detect and display progress
|
|
||||||
#TODO: determine when finished and then finished=1
|
|
||||||
|
|
||||||
echo "You can close terminal while reindex is running.."
|
echo "You can close terminal while reindex is running.."
|
||||||
echo "But you have to login again to check if ready."
|
echo "But you have to login again to check if ready."
|
||||||
|
|
||||||
@@ -83,9 +80,14 @@ while [ ${finished} -eq 0 ]
|
|||||||
|
|
||||||
done
|
done
|
||||||
|
|
||||||
|
|
||||||
# trigger reboot when finished
|
# trigger reboot when finished
|
||||||
echo "*************************"
|
echo "*************************"
|
||||||
|
if [ ${finished} -eq 0 ]; then
|
||||||
|
echo "Re-Index CANCELED"
|
||||||
|
else
|
||||||
echo "Re-Index finished"
|
echo "Re-Index finished"
|
||||||
|
fi
|
||||||
echo "Starting reboot ..."
|
echo "Starting reboot ..."
|
||||||
echo "*************************"
|
echo "*************************"
|
||||||
# stop bitcoind
|
# stop bitcoind
|
||||||
|
Reference in New Issue
Block a user