[Opensrf-commits] r1105 - trunk/bin
svn at svn.open-ils.org
svn at svn.open-ils.org
Wed Oct 10 18:03:07 EDT 2007
Author: dbs
Date: 2007-10-10 17:51:18 -0400 (Wed, 10 Oct 2007)
New Revision: 1105
Modified:
trunk/bin/osrf_ctl.sh
Log:
Enable -l flag to work without an argument
Modified: trunk/bin/osrf_ctl.sh
===================================================================
--- trunk/bin/osrf_ctl.sh 2007-10-10 20:58:39 UTC (rev 1104)
+++ trunk/bin/osrf_ctl.sh 2007-10-10 21:51:18 UTC (rev 1105)
@@ -12,9 +12,17 @@
function usage {
echo "";
- echo "usage: $0 -d <pid_dir> -c <c_config> -a <action>";
+ echo "usage: $0 [OPTION]... -c <c_config> -a <action>";
echo "";
- echo "Actions include:"
+ echo "Mandatory parameters:";
+ echo -e " -a\t\taction to perform";
+ echo -e " -c\t\tfull path to C configuration file (opensrf_core.xml)";
+ echo "";
+ echo "Optional parameters:";
+ echo -e " -d\t\tstore PID files in this directory";
+ echo -e " -l\t\taccept 'localhost' as the fully-qualified domain name";
+ echo "";
+ echo "Actions include:";
echo -e "\tstart_router"
echo -e "\tstop_router"
echo -e "\trestart_router"
@@ -31,9 +39,10 @@
echo -e "\tstart_all"
echo -e "\trestart_all"
echo "";
- echo "Example:";
- echo " $0 -c opensrf_core.xml -a restart_all";
- echo "";
+ echo "Examples:";
+ echo " $0 -c opensrf_core.xml -a restart_all";
+ echo " $0 -l -c opensrf_core.xml -a restart_all";
+ echo "";
exit;
}
@@ -41,7 +50,7 @@
# ---------------------------------------------------------------------------
# Load the command line options and set the global vars
# ---------------------------------------------------------------------------
-while getopts "c:a:d:l:h" flag; do
+while getopts "c:a:d:lh" flag; do
case $flag in
"a") OPT_ACTION="$OPTARG";;
"c") OPT_CONFIG="$OPTARG";;
More information about the opensrf-commits
mailing list