1 |
ikelos 07/09/16 15:30:58 |
2 |
|
3 |
Modified: vmware-workstation.rc |
4 |
Log: |
5 |
Alter init script to interoperate with baselayout-2 and unusual shells such as dash. |
6 |
(Portage version: 2.1.3.9) |
7 |
|
8 |
Revision Changes Path |
9 |
1.5 app-emulation/vmware-workstation/files/vmware-workstation.rc |
10 |
|
11 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/app-emulation/vmware-workstation/files/vmware-workstation.rc?rev=1.5&view=markup |
12 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/app-emulation/vmware-workstation/files/vmware-workstation.rc?rev=1.5&content-type=text/plain |
13 |
diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/app-emulation/vmware-workstation/files/vmware-workstation.rc?r1=1.4&r2=1.5 |
14 |
|
15 |
Index: vmware-workstation.rc |
16 |
=================================================================== |
17 |
RCS file: /var/cvsroot/gentoo-x86/app-emulation/vmware-workstation/files/vmware-workstation.rc,v |
18 |
retrieving revision 1.4 |
19 |
retrieving revision 1.5 |
20 |
diff -u -r1.4 -r1.5 |
21 |
--- vmware-workstation.rc 28 Apr 2007 10:04:05 -0000 1.4 |
22 |
+++ vmware-workstation.rc 16 Sep 2007 15:30:58 -0000 1.5 |
23 |
@@ -1,7 +1,7 @@ |
24 |
#!/sbin/runscript |
25 |
# Copyright 1999-2004 Gentoo Foundation |
26 |
# Distributed under the terms of the GNU General Public License v2 |
27 |
-# $Header: /var/cvsroot/gentoo-x86/app-emulation/vmware-workstation/files/vmware-workstation.rc,v 1.4 2007/04/28 10:04:05 ikelos Exp $ |
28 |
+# $Header: /var/cvsroot/gentoo-x86/app-emulation/vmware-workstation/files/vmware-workstation.rc,v 1.5 2007/09/16 15:30:58 ikelos Exp $ |
29 |
|
30 |
depend() { |
31 |
need localmount |
32 |
@@ -16,22 +16,22 @@ |
33 |
msgtype=0 |
34 |
while read line |
35 |
do |
36 |
- [[ "${line}" == "" ]] && continue |
37 |
- if [[ "${msgtype}" -le "0" ]] |
38 |
+ [ "$line" = "" ] && continue |
39 |
+ if [ ${msgtype} -le 0 ] |
40 |
then |
41 |
- if [[ "${msgtype}" == "-1" ]] |
42 |
+ if [ ${msgtype} -eq -1 ] |
43 |
then |
44 |
- ewarn ${line} |
45 |
+ ewarn $line |
46 |
continue |
47 |
fi |
48 |
- if [[ "${line/*:*/}" == "" ]] |
49 |
+ if echo ${line} | fgrep -q : |
50 |
then |
51 |
- einfon ${line} |
52 |
+ einfon $line |
53 |
echo |
54 |
eend 0 |
55 |
msgtype=1 |
56 |
else |
57 |
- ewarn ${line} |
58 |
+ ewarn $line |
59 |
msgtype=-1 |
60 |
waserror=1 |
61 |
fi |
62 |
@@ -39,25 +39,25 @@ |
63 |
fi |
64 |
|
65 |
# Strip out anything after the <esc> code |
66 |
- message=`echo ${line} | sed -e "s/^\(.*\).*$/\1/"` |
67 |
- einfon " ${message}" |
68 |
+ message=`echo $line | sed -e "s/^\(.*\).*$/\1/"` |
69 |
+ einfon " $message" |
70 |
echo |
71 |
|
72 |
- echo ${line} | grep done > /dev/null |
73 |
+ echo ${line} | grep -q done |
74 |
status=$? |
75 |
- eend ${status} |
76 |
+ eend $status |
77 |
|
78 |
- if [[ "${status}" != "0" ]] |
79 |
+ if [ $status -eq 0 ] |
80 |
then |
81 |
- logger -p local0.err -t vmware-${state} "${line}" |
82 |
- waserror=${status} |
83 |
+ logger -p local0.err -t vmware-${state} "$line" |
84 |
+ waserror=$status |
85 |
fi |
86 |
done |
87 |
- if [[ "${msgtype}" == "-1" ]] |
88 |
+ if [ "$msgtype" = "-1" ] |
89 |
then |
90 |
eend 1 "VMware is not properly configured! See above." |
91 |
fi |
92 |
- return ${waserror} |
93 |
+ return $waserror |
94 |
} |
95 |
|
96 |
start() { |
97 |
|
98 |
|
99 |
|
100 |
-- |
101 |
gentoo-commits@g.o mailing list |