From 7ad2324f9322c976505f2f1cc37bcf5391da6761 Mon Sep 17 00:00:00 2001 From: David Schroeder Date: Fri, 21 Apr 2023 21:20:30 -0500 Subject: [PATCH] Update mm-scripts.sh --- mm-scripts.sh | 47 ++++++++++++++++++++++++++--------------------- 1 file changed, 26 insertions(+), 21 deletions(-) diff --git a/mm-scripts.sh b/mm-scripts.sh index f900d11..55aa388 100755 --- a/mm-scripts.sh +++ b/mm-scripts.sh @@ -914,9 +914,12 @@ MMSETUP(){ echo read -n 1 -p "Do you wish to start services now (y/N)?" choice case "$choice" in - [Yy]) echo;MMSTART start;; esac + [Yy]) echo;MMSTART start;; + esac - /usr/local/bin/mm + echo -e "${idsCL[LightCyan]}The following are Media Manager (mm) usage commands:${idsCL[Default]}" + DIVIDER . lightGreen + USAGE # cat ${MMFOLDER}/settings.conf ;; @@ -929,6 +932,26 @@ MMSETUP(){ } +USAGE(){ + echo -e " Usage: ${idsCL[LightCyan]}mm {option}${idsCL[Default]}" + echo + echo -e " ${idsCL[Yellow]}start${idsCL[Default]} --> Start services" + echo -e " ${idsCL[Yellow]}stop${idsCL[Default]} --> Stop services" + echo -e " ${idsCL[Yellow]}restart${idsCL[Default]} --> Restart services" + echo -e " ${idsCL[Yellow]}update-allservices ${idsCL[Default]} --> Update all services" + echo -e " ${idsCL[Yellow]}update-service ${idsCL[Default]} --> Update specified service" + echo -e " ${idsCL[Yellow]}update-list${idsCL[Default]} --> List available releases" + echo + echo -e " ${idsCL[Yellow]}status${idsCL[Default]} --> Check Status on VPN and Media Services" + echo -e " ${idsCL[Yellow]}vpninfo${idsCL[Default]} --> Show VPN Info" + echo + echo -e " ${idsCL[Yellow]}check${idsCL[Default]} --> Crontab job for maintaining VPN & Media Services (run */1 min)" + echo -e " ${idsCL[Yellow]}clear${idsCL[Default]} --> Clear all tmp files" + echo -e " ${idsCL[Yellow]}update${idsCL[Default]} --> Check for and install new updates" + echo "" + echo "" +} + if [ ! -f ${MMFOLDER}/mm.update.stop ]; then if [ -f ${MMFOLDER}/mm.stop ]; then @@ -1022,25 +1045,7 @@ if [ ! -f ${MMFOLDER}/mm.update.stop ]; then echo ;; - *) - echo -e " Usage: ${idsCL[LightCyan]}mm {option}${idsCL[Default]}" - echo - echo -e " ${idsCL[Yellow]}start${idsCL[Default]} --> Start services" - echo -e " ${idsCL[Yellow]}stop${idsCL[Default]} --> Stop services" - echo -e " ${idsCL[Yellow]}restart${idsCL[Default]} --> Restart services" - echo -e " ${idsCL[Yellow]}update-allservices ${idsCL[Default]} --> Update all services" - echo -e " ${idsCL[Yellow]}update-service ${idsCL[Default]} --> Update specified service" - echo -e " ${idsCL[Yellow]}update-list${idsCL[Default]} --> List available releases" - echo - echo -e " ${idsCL[Yellow]}status${idsCL[Default]} --> Check Status on VPN and Media Services" - echo -e " ${idsCL[Yellow]}vpninfo${idsCL[Default]} --> Show VPN Info" - echo - echo -e " ${idsCL[Yellow]}check${idsCL[Default]} --> Crontab job for maintaining VPN & Media Services (run */1 min)" - echo -e " ${idsCL[Yellow]}clear${idsCL[Default]} --> Clear all tmp files" - echo -e " ${idsCL[Yellow]}update${idsCL[Default]} --> Check for and install new updates" - echo "" - echo "" - exit 0;; + *) USAGE;; esac else