]> git.pld-linux.org Git - packages/dictd.git/commitdiff
- updated
authorankry <ankry@pld-linux.org>
Fri, 2 May 2003 23:38:07 +0000 (23:38 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    dictd.init -> 1.4

dictd.init

index 2f2f6a865b3a1d599838d5789a72d561ad7aef11..c5fd58cc8bc8a52f2f290fb136d3e3f67164891b 100644 (file)
@@ -4,12 +4,12 @@
 #
 # chkconfig:   345 90 10
 # description: This is a daemon for the Dictionary Server Protocol (DICT), \
-#               a TCP transaction based query/response protocol that allows \
-#               a client to access dictionary definitions from a set of \
+#              a TCP transaction based query/response protocol that allows \
+#              a client to access dictionary definitions from a set of \
 #              natural language dictionary databases.
 # processname: dictd
 # config:      /etc/dictd.conf 
-# config:       /etc/dictd/*
+# config:      /etc/dictd/*
 
 DAEMON_FILE=dictd
 DAEMON_NAME="Dictionary Daemon"  
@@ -20,12 +20,12 @@ generate_dictdconf() {
     if ls /etc/dictd/*.dictconf >/dev/null 2>&1; then 
        echo "# DO NOT EDIT! This file is autogenerated by $0." >$DAEMON_CONF
        echo "# To configure dictd edit /etc/dictd/* files and restart daemon"\
-          >>$DAEMON_CONF
+           >>$DAEMON_CONF
        cat /etc/dictd/dictd-main.conf /etc/dictd/*.dictconf >>$DAEMON_CONF
        return 0
     fi 
 
-    echo "$0: no dictionaries found"
+    echo "$0: $(nls 'no dictionaries found')"
     return 1   
 }
 
@@ -37,7 +37,7 @@ generate_dictdconf() {
 
 if is_no "${NETWORKING}"; then
        msg_network_down ${DAEMON_FILE}
-        exit 1
+       exit 1
 fi
 
 # Get sysconfig
@@ -46,24 +46,25 @@ fi
 RETVAL=0
 # See how we were called.
 case "$1" in
-    start)
+  start)
        [ -x /usr/sbin/${DAEMON_FILE} ] || exit 0
        if [ ! -f /var/lock/subsys/${DAEMON_FILE} ]; then
                if generate_dictdconf; then 
-                   msg_starting ${DAEMON_NAME}
-                   daemon ${DAEMON_FILE} ${DICTD_OPTS}
-                   pidofproc ${DAEMON_FILE} >/dev/null 2>&1
-                   RETVAL=$?
-                   [ $RETVAL -eq 0 ] && touch /var/lock/subsys/${DAEMON_FILE}
+                       msg_starting ${DAEMON_NAME}
+                       daemon ${DAEMON_FILE} ${DICTD_OPTS}
+                       pidofproc ${DAEMON_FILE} >/dev/null 2>&1
+                       RETVAL=$?
+                       [ $RETVAL -eq 0 ] && \
+                           touch /var/lock/subsys/${DAEMON_FILE}
                else  
-                   exit 1
+                       exit 1
                fi    
        else
                msg_already_running ${DAEMON_NAME}
                exit 1
        fi
         ;;
-    stop)
+  stop)
        if [ -f /var/lock/subsys/${DAEMON_FILE} ]; then
                msg_stopping ${DAEMON_NAME}
                busy
@@ -82,7 +83,7 @@ case "$1" in
         $0 start
         ;;
     *)
-       msg_usage "$0 {start|stop|status|restart|reload}"
+       msg_usage "$0 {start|stop|restart|reload|status}"
        exit 1
        ;;
 esac
This page took 0.075388 seconds and 4 git commands to generate.