wok diff nscd/stuff/nscd @ rev 25063
nfs-utils: update web_site
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Tue Jun 07 20:10:22 2022 +0000 (2022-06-07) |
parents | 2ae8ee18aa85 |
children |
line diff
1.1 --- a/nscd/stuff/nscd Sat May 28 11:59:26 2011 +0200 1.2 +++ b/nscd/stuff/nscd Tue Jun 07 20:10:22 2022 +0000 1.3 @@ -9,7 +9,7 @@ 1.4 . /etc/daemons.conf 1.5 1.6 NAME=nscd 1.7 -DESC="Name Switch Cache Daemon" 1.8 +DESC="$(_ 'name-server caching daemon')" 1.9 DAEMON=/usr/sbin/nscd 1.10 OPTIONS=$NSCD_OPTIONS 1.11 PIDFILE=/var/run/nscd/nscd.pid 1.12 @@ -20,41 +20,39 @@ 1.13 case "$1" in 1.14 start) 1.15 if active_pidfile $PIDFILE nscd ; then 1.16 - echo "$NAME already running." 1.17 + _ '%s is already running.' $NAME 1.18 exit 1 1.19 fi 1.20 - echo -n "Starting $DESC: $NAME... " 1.21 + action 'Starting %s: %s...' "$DESC" $NAME 1.22 $DAEMON $OPTIONS 1.23 status 1.24 sleep 2 1.25 ;; 1.26 stop) 1.27 if ! active_pidfile $PIDFILE nscd ; then 1.28 - echo "$NAME is not running." 1.29 + _ '%s is not running.' $NAME 1.30 exit 1 1.31 fi 1.32 - echo -n "Stopping $DESC: $NAME... " 1.33 - kill `cat $PIDFILE` 1.34 + action 'Stopping %s: %s...' "$DESC" $NAME 1.35 + kill $(cat $PIDFILE) 1.36 status 1.37 sleep 2 1.38 ;; 1.39 restart) 1.40 if ! active_pidfile $PIDFILE nscd ; then 1.41 - echo "$NAME is not running." 1.42 + _ '%s is not running.' $NAME 1.43 exit 1 1.44 fi 1.45 - echo -n "Restarting $DESC: $NAME... " 1.46 - kill `cat $PIDFILE` 1.47 + action 'Restarting %s: %s...' "$DESC" $NAME 1.48 + kill $(cat $PIDFILE) 1.49 sleep 2 1.50 $DAEMON $OPTIONS 1.51 status 1.52 sleep 2 1.53 ;; 1.54 *) 1.55 - echo "" 1.56 - echo -e "\033[1mUsage:\033[0m /etc/init.d/`basename $0` [start|stop|restart 1.57 -]" 1.58 - echo "" 1.59 + emsg "<n><b>$(_ 'Usage:')</b> $0 [start|stop|restart]" 1.60 + newline 1.61 exit 1 1.62 ;; 1.63 esac