]> git.pld-linux.org Git - packages/gdm.git/blame - gdm.init
This commit was manufactured by cvs2git to create branch 'RA-branch'.
[packages/gdm.git] / gdm.init
CommitLineData
708ea193 1#!/bin/sh
2#
3# gdm: Starts the Gnome Display Manager
4#
f973d2c9 5# Version: @(#) /etc/rc.d/init.d/gdm 0.1
708ea193 6#
d669e859 7# chkconfig: 5 95 5
f973d2c9 8# description: Starts and stops the Gnome Display Manager at startup and \
708ea193 9# shutdown..
10#
11# config: /etc/X11/gdm/gdm-config
12# probe: true
13# hide: true
14
15. /etc/rc.d/init.d/functions
16
17# Get service config
f973d2c9 18if [ -f /etc/sysconfig/gdm ]; then
19 . /etc/sysconfig/gdm
708ea193 20fi
21
f973d2c9 22RETVAL=0
708ea193 23# See how we were called.
24case "$1" in
25 start)
26 # Check if the service is already running?
27 if [ ! -f /var/lock/subsys/gdm ]; then
28 msg_starting "Gnome Display Manager"
607c7bc4 29 daemon open /usr/X11R6/bin/gdm
eb18af7f 30 RETVAL=$?
554969be 31 [ $RETVAL -eq 0 ] && touch /var/lock/subsys/gdm
708ea193 32 else
f973d2c9 33 msg_already_running "Gnome Display Manager"
708ea193 34 fi
35 ;;
36 stop)
eb18af7f 37 if [ -f /var/lock/subsys/gdm ]; then
38 msg_stopping "Gnome Display Manager"
39 killproc gdm
40 rm -f /var/lock/subsys/gdm
41 else
f973d2c9 42 msg_not_running "Gnome Display Manager"
eb18af7f 43 fi
708ea193 44 ;;
45 status)
46 status gdm
f973d2c9 47 exit $?
708ea193 48 ;;
f973d2c9 49 restart|force-reload)
708ea193 50 $0 stop
51 $0 start
f973d2c9 52 exit $?
708ea193 53 ;;
54 *)
f973d2c9 55 msg_usage "$0 {start|stop|restart|force-reload|status}"
56 exit 3
708ea193 57esac
58
eb18af7f 59exit $RETVAL
This page took 0.036632 seconds and 4 git commands to generate.