Slackware rc file patch - geomyidae - A small C-based gopherd. HTML git clone git://bitreich.org/geomyidae/ git://enlrupgkhuxnvlhsf6lc3fziv5h2hhfrinws65d7roiv6bfj7d652fid.onion/geomyidae/ DIR Log DIR Files DIR Refs DIR Tags DIR README DIR LICENSE --- DIR commit a92eba598604e4892b536e3f2b88f5d745414ba8 DIR parent 7d6e2741cba15fa46a3f19c6bfcaa47f6feb558b HTML Author: David Woodfall <dave@dawoodfall.net> Date: Tue, 14 Nov 2017 17:58:34 +0000 Slackware rc file patch Hello A patch that adds a slackware rc file for geomyidae. Bye Signed-off-by: Christoph Lohmann <20h@r-36.net> Diffstat: A rc.d/rc.geomyidae | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+), 0 deletions(-) --- DIR diff --git a/rc.d/rc.geomyidae b/rc.d/rc.geomyidae @@ -0,0 +1,31 @@ +#!/bin/sh + +# rc file for Slackware Linux. +# This lives in /ect/rc.d/ + +PID=$(pidof -o %PPID /usr/bin/geomyidae) + +case "$1" in + start) + echo "Starting geomyidae" + [ -z "$PID" ] && /usr/bin/geomyidae $GEOMYIDAE_ARGS 2>&1 + if [ $? -gt 0 ]; then + echo "Startup failed" + fi + ;; + stop) + echo "Stopping geomyidae" + [ -n "$PID" ] && kill $PID &>/dev/null + if [ $? -gt 0 ]; then + echo "Stopping failed" + fi + ;; + restart) + $0 stop + $0 start + ;; + *) + echo "usage: $0 {start|stop|restart}" +esac +exit 0 +