updated on Wed Jan 25 08:34:36 UTC 2012
[aur-mirror.git] / firestarter-gtkstatusicon / rc.firestarter
blobef30d50f4b4e9fd9d6990be7dc808581e41dc1c7
1 #!/bin/bash
3 daemon_name=firestarter
5 . /etc/rc.conf
6 . /etc/rc.d/functions
8 FS='/etc/firestarter/firestarter.sh'
10 case "$1" in
11 start)
12 stat_busy "Starting $daemon_name"
14 # Call firestarter script
15 $FS start > /dev/null
17 if [ $? -gt 0 ]; then
18 stat_fail
19 exit 1
20 else
21 add_daemon $daemon_name
22 stat_done
26 stop)
27 stat_busy "Stopping $daemon_name daemon"
29 # Call firestarter script
30 $FS stop > /dev/null
32 if [ $? -gt 0 ]; then
33 stat_fail
34 exit 1
35 else
36 rm_daemon $daemon_name
37 stat_done
41 restart)
42 $0 stop
43 $0 start
46 status)
47 stat_busy "Checking $daemon_name status";
48 ck_status $daemon_name
52 echo "usage: $0 {start|stop|restart|status}"
53 esac
55 exit 0