From 5e925e2c4bdbf3be14a77f7a23b08fbcad24d652 Mon Sep 17 00:00:00 2001 From: openoms Date: Tue, 10 Aug 2021 11:41:02 +0100 Subject: [PATCH] use $lightning option for INFO --- home.admin/00mainMenu.sh | 4 +-- home.admin/00parallelChainsMenu.sh | 56 ++++++++++++++++-------------- 2 files changed, 31 insertions(+), 29 deletions(-) diff --git a/home.admin/00mainMenu.sh b/home.admin/00mainMenu.sh index 8c47df6a5..d59171a81 100755 --- a/home.admin/00mainMenu.sh +++ b/home.admin/00mainMenu.sh @@ -199,7 +199,7 @@ case $CHOICE in do # show the same info as on LCD screen - /home/admin/00infoBlitz.sh + /home/admin/00infoBlitz.sh ${lightning} ${chain}net # wait 6 seconds for user exiting loop echo "" @@ -217,7 +217,7 @@ case $CHOICE in done else - /home/admin/00raspiblitz.sh + /home/admin/00raspiblitz.sh ${lightning} ${chain}net exit 0 fi ;; diff --git a/home.admin/00parallelChainsMenu.sh b/home.admin/00parallelChainsMenu.sh index cd4c13e1f..d1a1bb90d 100644 --- a/home.admin/00parallelChainsMenu.sh +++ b/home.admin/00parallelChainsMenu.sh @@ -121,33 +121,35 @@ CHOICE=$(dialog --clear \ case $CHOICE in INFO) - # #TODO - # echo "Gathering Information (please wait) ..." - # walletLocked=$(lncli getinfo 2>&1 | grep -c "Wallet is encrypted") - # if [ ${walletLocked} -eq 0 ]; then - # while : - # do - # # show the same info as on LCD screen - # /home/admin/00infoBlitz.sh - # # wait 6 seconds for user exiting loop - # echo "" - # echo -en "Screen is updating in a loop .... press 'x' now to get back to menu." - # read -n 1 -t 6 keyPressed - # echo -en "\rGathering information to update info ... please wait. \n" - # # check if user wants to abort session - # if [ "${keyPressed}" = "x" ]; then - # echo "" - # echo "Returning to menu ....." - # sleep 4 - # break - # fi - # done - # else - # /home/admin/00raspiblitz.sh - # exit 0 - # fi - /home/admin/00infoBlitz.sh $CHAIN - ;; + echo "Gathering Information (please wait) ..." + walletLocked=$(lncli getinfo 2>&1 | grep -c "Wallet is encrypted") + if [ ${walletLocked} -eq 0 ]; then + while : + do + + # show the same info as on LCD screen + /home/admin/00infoBlitz.sh ${lightning} ${chain}net + + # wait 6 seconds for user exiting loop + echo "" + echo -en "Screen is updating in a loop .... press 'x' now to get back to menu." + read -n 1 -t 6 keyPressed + echo -en "\rGathering information to update info ... please wait. \n" + + # check if user wants to abort session + if [ "${keyPressed}" = "x" ]; then + echo "" + echo "Returning to menu ....." + sleep 4 + break + fi + done + + else + /home/admin/00raspiblitz.sh ${lightning} ${chain}net + exit 0 + fi + ;; RTL) /home/admin/config.scripts/bonus.rtl.sh menu lnd $CHAIN ;;