rclone_script-install-dialog.sh

* moved each main step into its own function for readability
* added steps 3a to 4b
rclone_sync-menu.sh
* added new file
This commit is contained in:
Jandalf81
2018-08-12 14:18:25 +02:00
parent 41b666619c
commit 9b1799b71b
2 changed files with 290 additions and 79 deletions

40
rclone_sync-menu.sh Normal file
View File

@@ -0,0 +1,40 @@
#!/bin/bash
NORMAL="\Zn"
BLACK="\Z0"
RED="\Z1"
GREEN="\Z2"
YELLOW="\Z3"
BLUE="\Z4"
MAGENTA="\Z5"
CYAN="\Z6"
WHITE="\Z7"
BOLD="\Zb"
REVERSE="\Zr"
UNDERLINE="\Zu"
function main_menu ()
{
local choice
while true
do
choice=$(dialog \
--stdout \
--ascii-lines \
--backtitle "RCLONE_SCRIPT menu" \
--title "main menu" \
--menu "\nWhat do you want to do?" 25 75 20 \
1 "Full sync" \
9 "uninstall"
)
case "$choice" in
1) ~/scripts/rclone_script/rclone_script.sh "full" ;;
9) ~/scripts/rclone_script/rclone_script-uninstall.sh
*) break ;;
esac
done
}