[SCM] [contrib] Quake III: Arena launcher branch, master, updated. debian/1.0-7-g99d3326

Simon McVittie smcv at debian.org
Thu Nov 11 22:48:39 UTC 2010


The following commit has been merged in the master branch:
commit 99d33262d02a99476a13bc8288ff61866c958582
Author: Simon McVittie <smcv at debian.org>
Date:   Thu Nov 11 19:58:13 2010 +0000

    quake3-server.init: parameterize so we can use it for OA with minor changes

diff --git a/debian/quake3-server.init b/debian/quake3-server.init
index bd3e3ec..7ba059d 100644
--- a/debian/quake3-server.init
+++ b/debian/quake3-server.init
@@ -9,19 +9,20 @@
 ### END INIT INFO
 
 PATH="/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin"
-DAEMON="/usr/games/quake3-server"
 NAME="quake3-server"
+DAEMON="/usr/games/$NAME"
 DESC="Quake III Arena dedicated server"
 PIDFILE="/var/run/$NAME.pid"
 BINARY="/usr/lib/ioquake3/ioq3ded"
+USER="Debian-quake3"
 
 test -x $DAEMON || exit 0
 
 . /lib/lsb/init-functions
 
 # Include defaults if available
-if [ -f /etc/default/quake3-server ] ; then
-	. /etc/default/quake3-server
+if [ -f /etc/default/$NAME ] ; then
+	. /etc/default/$NAME
 fi
 
 q3_start() {
@@ -29,12 +30,12 @@ q3_start() {
         return 2
     fi
     if [ "$START_DAEMON" != 1 ]; then
-        echo -n " (not starting - disabled in /etc/default/quake3-server)"
+        echo -n " (not starting - disabled in /etc/default/$NAME)"
         return 0
     fi
     start-stop-daemon --start --quiet --pidfile $PIDFILE --oknodo \
 	--background --exec $BINARY --startas $DAEMON \
-	--make-pidfile --chuid Debian-quake3 \
+	--make-pidfile --chuid $USER \
 	-- $DAEMON_OPTS > /dev/null 2>&1 || return 1
     return 0
 }

-- 
[contrib] Quake III: Arena launcher



More information about the Pkg-games-commits mailing list