[pkg-fso-commits] [SCM] gpsd for fso branch, debian, updated. debian/0.8-2-20-gf2387cf
Luca Capello
luca at pca.it
Fri May 29 00:02:13 UTC 2009
The following commit has been merged in the debian branch:
commit 15cb796d296dfa8ee70462aa307852ed96f9b80a
Author: Luca Capello <luca at pca.it>
Date: Fri May 29 00:24:38 2009 +0200
debian/fso-gpsd.init: VERBOSE variable and LSB log_* functions
diff --git a/debian/changelog b/debian/changelog
index d21d299..d6c2fdf 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -17,6 +17,7 @@ fso-gpsd (0.8-3) UNRELEASED; urgency=low
+ use PIDDIR and PIDFILE variables.
+ use test brackets to check if the package has been removed
but not purged (and add a useful comment).
+ + use VERBOSE variable and LSB log_* functions to control output.
+ add --oknodo to start case (Standards-Version 3.8.1).
+ simplify restart/force-reload case.
+ do not hardcode path for usage output.
diff --git a/debian/fso-gpsd.init b/debian/fso-gpsd.init
index cd20813..8d2e99f 100644
--- a/debian/fso-gpsd.init
+++ b/debian/fso-gpsd.init
@@ -33,24 +33,31 @@ DAEMON_OPTS="-S localhost:gpsd -P $PIDFILE"
[ -x "$DAEMON" ] || exit 0
+# Load the VERBOSE setting and other rcS variables
+. /lib/init/vars.sh
+
+# Define LSB log_* functions.
+. /lib/lsb/init-functions
+
+
case "$1" in
start)
- echo -n "Starting $DESC: "
+ [ "$VERBOSE" != no ] && log_daemon_msg "Starting $DESC" "$NAME"
start-stop-daemon --oknodo --start --quiet --pidfile ${PIDFILE} \
--exec $DAEMON -- $DAEMON_OPTS
- echo "$NAME."
+ [ "$VERBOSE" != no ] && log_end_msg $?
;;
stop)
- echo -n "Stopping $DESC: "
+ [ "$VERBOSE" != no ] && log_daemon_msg "Stopping $DESC" "$NAME"
start-stop-daemon --oknodo --stop --quiet --pidfile ${PIDFILE}
- echo "$NAME."
+ [ "$VERBOSE" != no ] && log_end_msg $?
;;
restart|force-reload)
$0 stop
$0 start
;;
*)
- echo "Usage: $0 {start|stop|restart|force-reload}" >&2
+ log_success_msg "Usage: $0 {start|stop|restart|force-reload}" >&2
exit 1
;;
esac
--
gpsd for fso
More information about the pkg-fso-commits
mailing list