update the handling of input for monitor admin GenaSYS-2.4.0
authorAndy Witter <awitter@georgialibraries.org>
Wed, 2 Oct 2013 02:59:02 +0000 (22:59 -0400)
committerAndy Witter <awitter@georgialibraries.org>
Wed, 2 Oct 2013 02:59:02 +0000 (22:59 -0400)
GenaSYS.sh

index e927605..e7f3d4f 100755 (executable)
@@ -25,8 +25,8 @@
     PURPOSE_="Generate config files needed for Evergreen-ILS Cluster"
    SYNOPSIS_="$NAME_"
    REQUIRES_="standard GNU commands, apt, dpkg"
-    VERSION_="1.13"
-       DATE_="2010-09-18; last update: 2013-08-07"
+    VERSION_="1.14"
+       DATE_="2010-09-23; last update: 2013-08-07"
      AUTHOR_="Andy Witter <awitter@georgialibraries.org>"
         URL_="http://evergreen-ils.org"
    CATEGORY_="devel"
@@ -768,12 +768,9 @@ echo "In order to configure monitoring for the cluster,"
 echo "(Icinga/Nagios, PhP4Nagios, and Munin) we need to"
 echo "configure the admin credentials and email contact."
 read -p "Enter a monitoring admin username. eg monitoradmin: " MONITOR_ADMIN_USERNAME
-if [ "$MONITOR_ADMIN_USERNAME" = "" ] 
-then
-       MONITOR_ADMIN_USERNAME="monitoradmin"
+       [ -z "$MONITOR_ADMIN_USERNAME" ] && MONITOR_ADMIN_USERNAME="monitoradmin"
        echo
-       echo -e "Setting the monitor admin username to: "$COL_BR_CYAN"monitoradmin"$COL_RESET
-fi
+       echo -e "Setting the monitor admin username to: "$COL_BR_CYAN"$MONITOR_ADMIN_USERNAME"$COL_RESET
 echo
 }