summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2006-07-01 00:48:30 +0000
committerMike Frysinger <vapier@gentoo.org>2006-07-01 00:48:30 +0000
commit66728bcee36bd4fff3ac4984e99d7ae9d8e9dc22 (patch)
treed268719ae7f28a2c14925cd7fd4b5030f69fd324 /x11-apps/xinit/files
parentstable on ppc sparc alpha arm sh (diff)
downloadgentoo-2-66728bcee36bd4fff3ac4984e99d7ae9d8e9dc22.tar.gz
gentoo-2-66728bcee36bd4fff3ac4984e99d7ae9d8e9dc22.tar.bz2
gentoo-2-66728bcee36bd4fff3ac4984e99d7ae9d8e9dc22.zip
Use cooler bash syntax.
(Portage version: 2.1.1_pre1-r5)
Diffstat (limited to 'x11-apps/xinit/files')
-rw-r--r--x11-apps/xinit/files/startDM.sh16
1 files changed, 7 insertions, 9 deletions
diff --git a/x11-apps/xinit/files/startDM.sh b/x11-apps/xinit/files/startDM.sh
index ad2c9ead627a..f308271a1146 100644
--- a/x11-apps/xinit/files/startDM.sh
+++ b/x11-apps/xinit/files/startDM.sh
@@ -1,8 +1,9 @@
#!/bin/bash
-# Copyright 1999-2004 Gentoo Foundation
+# Copyright 1999-2006 Gentoo Foundation
# Distributed under the terms of the GNU General Public License, v2
+# $Header: /var/cvsroot/gentoo-x86/x11-apps/xinit/files/startDM.sh,v 1.2 2006/07/01 00:48:30 vapier Exp $
+#
# Author: Martin Schlemmer <azarah@gentoo.org>
-# $Header: /var/cvsroot/gentoo-x86/x11-apps/xinit/files/startDM.sh,v 1.1 2005/08/14 00:12:39 spyderous Exp $
source /etc/init.d/functions.sh
@@ -14,18 +15,16 @@ source /etc/profile
# We enable this by default
export GDK_USE_XFT=1
-if [ -e ${svcdir}/options/xdm/service ]
-then
+if [[ -e ${svcdir}/options/xdm/service ]] ; then
retval=0
- EXE="`cat ${svcdir}/options/xdm/service`"
+ EXE=$(<"${svcdir}"/options/xdm/service)
/sbin/start-stop-daemon --start --quiet --exec ${EXE}
retval=$?
# Fix bug #26125 for slower systems
wait; sleep 2
-
- if [ "${retval}" -ne 0 ]
- then
+
+ if [[ ${retval} -ne 0 ]] ; then
# there was a error running the DM
einfo "ERROR: could not start the Display Manager..."
# make sure we do not have a misbehaving DM
@@ -33,5 +32,4 @@ then
fi
fi
-
# vim:ts=4