Magellan Linux

Annotation of /trunk/hotplug/hotplug.rc

Parent Directory Parent Directory | Revision Log Revision Log


Revision 28 - (hide annotations) (download)
Sat Jul 2 17:07:55 2005 UTC (18 years, 10 months ago) by niro
File size: 903 byte(s)
new

1 niro 28 #!/bin/bash
2     # $Header: /root/magellan-cvs/src/hotplug/hotplug.rc,v 1.1 2005-07-02 17:07:55 niro Exp $
3    
4     #%rlevels: 0:k 1:k 6:k 7:s
5     #%start: 56
6     #%stop: 55
7    
8     #deps
9     #%needs:
10     #%before:
11     #%after:
12    
13     source /etc/sysconfig/rc
14     source $rc_functions
15    
16     case $1 in
17     start)
18     if [ ! -d /etc/hotplug ]
19     then
20     echo "Please install sys-apps/hotplug"
21     exit 1
22     fi
23    
24     for i in /etc/hotplug/*.rc
25     do
26     echo -e ${COLOREDSTAR}"Starting hotplug for $(basename ${i} .rc) devices"
27     ${i} start
28     evaluate_retval
29     done
30    
31     update_svcstatus $1
32     splash svc_started "$(basename $0)" 0
33     ;;
34    
35     stop)
36     for i in /etc/hotplug/*.rc
37     do
38     echo -e ${COLOREDSTAR}"Stopping hotplug for $(basename ${i} .rc) devices"
39     ${i} stop
40     evaluate_retval
41     done
42    
43     update_svcstatus $1
44     splash svc_stopped "$(basename $0)" 0
45     ;;
46    
47     restart)
48     $0 stop
49     sleep 1
50     $0 start
51     ;;
52    
53     *)
54     echo "Usage: $0 {start|stop|restart}"
55     exit 1
56     ;;
57     esac

Properties

Name Value
svn:executable *