Magellan Linux

Contents of /alx-src/trunk/tinyalxconfig-ng/init.d/single-x11

Parent Directory Parent Directory | Revision Log Revision Log


Revision 508 - (show annotations) (download)
Tue Jun 17 19:01:42 2008 UTC (15 years, 10 months ago) by niro
File size: 783 byte(s)
-added single X11 start script

1 #!/bin/sh
2 # $Header: /home/cvsd/alx-cvs/alx-src/tinyalxconfig-ng/init.d/single-x11,v 1.1 2008-06-17 19:01:42 niro Exp $
3
4 #%rlevels: 3:s 0:k
5 #%start: 99
6 #%stop: 00
7
8 #deps
9 #%needs:
10 #%before:
11 #%after:
12
13 source /etc/conf.d/rc
14 source ${rc_functions}
15
16 case "$1" in
17 start)
18 echo -e ${COLOREDSTAR}"Starting a single X11 session ..."
19 loadproc /usr/bin/startx &> /dev/null
20 evaluate_retval
21
22 update_svcstatus $1
23 splash svc_started "$(basename $0)" 0
24 ;;
25
26 stop)
27 echo -e ${COLOREDSTAR}"Stopping single X11 session ..."
28 killproc /usr/bin/X
29 evaluate_retval
30
31 update_svcstatus $1
32 splash svc_stopped "$(basename $0)" 0
33 ;;
34
35 restart)
36 $0 stop
37 sleep 1
38 $0 start
39 ;;
40
41 status)
42 statusproc /usr/bin/X
43 ;;
44
45 *)
46 echo "Usage: $0 {start|stop|restart|status}"
47 exit 1
48 ;;
49 esac