Pi.Alert 3.01

This commit is contained in:
pucherot
2021-04-22 23:10:49 +02:00
parent 77b4858d5f
commit 5a67648b7d
5 changed files with 10 additions and 10 deletions

View File

@@ -16,11 +16,11 @@ Estimated time: 20'
## One-step Automated Install: ## One-step Automated Install:
<!--- --------------------------------------------------------------------- ---> <!--- --------------------------------------------------------------------- --->
`curl -sSL https://github.com/pucherot/Pi.Alert/raw/main/install/pialert_install.sh | bash` #### `curl -sSL https://github.com/pucherot/Pi.Alert/raw/main/install/pialert_install.sh | bash`
## One-step Automated Update: ## One-step Automated Update:
<!--- --------------------------------------------------------------------- ---> <!--- --------------------------------------------------------------------- --->
`curl -sSL https://github.com/pucherot/Pi.Alert/raw/main/install/pialert_update.sh | bash` #### `curl -sSL https://github.com/pucherot/Pi.Alert/raw/main/install/pialert_update.sh | bash`
## Uninstall process ## Uninstall process
<!--- --------------------------------------------------------------------- ---> <!--- --------------------------------------------------------------------- --->

View File

@@ -5,7 +5,7 @@ Estimated time: 5'
## One-step Automated Uninstall: ## One-step Automated Uninstall:
<!--- --------------------------------------------------------------------- ---> <!--- --------------------------------------------------------------------- --->
`curl -sSL https://github.com/pucherot/Pi.Alert/raw/main/install/pialert_uninstall.sh | bash` #### `curl -sSL https://github.com/pucherot/Pi.Alert/raw/main/install/pialert_uninstall.sh | bash`
## Uninstallation process (step by step) ## Uninstallation process (step by step)
<!--- --------------------------------------------------------------------- ---> <!--- --------------------------------------------------------------------- --->

View File

@@ -78,7 +78,7 @@ msgbox() {
END_DIALOG=false END_DIALOG=false
while ! $END_DIALOG ; do while ! $END_DIALOG ; do
whiptail --title "Pi.Alert Installation" --msgbox "$LINE1\\n\\n$LINE2" $ROWS $COLS whiptail --title "Pi.Alert Uninstallation" --msgbox "$LINE1\\n\\n$LINE2" $ROWS $COLS
BUTTON=$? BUTTON=$?
ask_cancel ask_cancel
ANSWER=true ANSWER=true
@@ -97,7 +97,7 @@ ask_yesno() {
END_DIALOG=false END_DIALOG=false
while ! $END_DIALOG ; do while ! $END_DIALOG ; do
whiptail --title "Pi.Alert Installation" --yesno $DEF_BUTTON "$LINE1\\n\\n$LINE2" $ROWS $COLS whiptail --title "Pi.Alert Uninstallation" --yesno $DEF_BUTTON "$LINE1\\n\\n$LINE2" $ROWS $COLS
BUTTON=$? BUTTON=$?
ask_cancel ask_cancel
done done
@@ -115,7 +115,7 @@ ask_option() {
END_DIALOG=false END_DIALOG=false
while ! $END_DIALOG ; do while ! $END_DIALOG ; do
ANSWER=$(whiptail --title "Pi.Alert Installation" --menu "$1" $ROWS $COLS "${MENU_ARGS[@]}" 3>&2 2>&1 1>&3 ) ANSWER=$(whiptail --title "Pi.Alert Uninstallation" --menu "$1" $ROWS $COLS "${MENU_ARGS[@]}" 3>&2 2>&1 1>&3 )
BUTTON=$? BUTTON=$?
ask_cancel CANCEL ask_cancel CANCEL
done done
@@ -127,7 +127,7 @@ ask_input() {
END_DIALOG=false END_DIALOG=false
while ! $END_DIALOG ; do while ! $END_DIALOG ; do
ANSWER=$(whiptail --title "Pi.Alert Installation" --inputbox "$LINE1\\n\\n$LINE2" $ROWS $COLS "$3" 3>&2 2>&1 1>&3 ) ANSWER=$(whiptail --title "Pi.Alert Uninstallation" --inputbox "$LINE1\\n\\n$LINE2" $ROWS $COLS "$3" 3>&2 2>&1 1>&3 )
BUTTON=$? BUTTON=$?
ask_cancel CANCEL ask_cancel CANCEL
@@ -139,16 +139,16 @@ ask_input() {
} }
ask_cancel() { ask_cancel() {
LINE0="Do you want to cancel the installation process" LINE0="Do you want to cancel the uninstallation process"
LINE0=$(printf "\n\n%*s" $(((${#LINE0}+$COLS-5)/2)) "$LINE0") LINE0=$(printf "\n\n%*s" $(((${#LINE0}+$COLS-5)/2)) "$LINE0")
if [ "$BUTTON" = "1" ] && [ "$1" = "CANCEL" ] ; then BUTTON="255"; fi if [ "$BUTTON" = "1" ] && [ "$1" = "CANCEL" ] ; then BUTTON="255"; fi
if [ "$BUTTON" = "255" ] ; then if [ "$BUTTON" = "255" ] ; then
whiptail --title "Pi.Alert Installation" --yesno --defaultno "$LINE0" $ROWS $COLS whiptail --title "Pi.Alert Uninstallation" --yesno --defaultno "$LINE0" $ROWS $COLS
if [ "$?" = "0" ] ; then if [ "$?" = "0" ] ; then
process_error "Installation Aborted by User" process_error "Uninstallation Aborted by User"
fi fi
else else
END_DIALOG=true END_DIALOG=true

Binary file not shown.

Binary file not shown.