1
0
mirror of https://github.com/gryf/wicd.git synced 2025-12-31 02:52:29 +01:00
Files
wicd/data/init/suse/wicd
gryf 0ef443f97c Removed bin/sbin out of config options.
Let's do this in pythonic way, optionally leave the decision to package
maintainers, where to put binaries.
2020-08-31 21:12:30 +02:00

52 lines
1.2 KiB
Bash
Executable File

#! /bin/sh
### BEGIN INIT INFO
# Provides: wicd-daemon
# Required-Start: dbus
# Required-Stop: $null
# Default-Start: 3 4 5
# Default-Stop:
# Description: wicd, a wired and wireless connection manager.
### END INIT INFO
WICD_BIN=/usr/bin/wicd
test -x $WICD_BIN || exit 5
. /etc/rc.status
rc_reset
case "$1" in
start)
checkproc $WICD_BIN
if [ $? = 0 ]; then
echo -n "wicd already running"
rc_status -v
rc_exit
fi
echo -n "Starting wicd"
startproc $WICD_BIN
rc_status -v
;;
stop)
echo -n "Shutting down wicd"
killproc -TERM $WICD_BIN
rc_status -v
;;
restart)
$0 stop
$0 start
rc_status
;;
status)
echo -n "Checking for wicd: "
checkproc $WICD_BIN
rc_status -v
;;
*)
echo "Usage: $0 {start|stop|status|restart}"
exit 1
;;
esac