equal
deleted
inserted
replaced
21 # |
21 # |
22 |
22 |
23 # |
23 # |
24 # Copyright 2008 Sun Microsystems, Inc. All rights reserved. |
24 # Copyright 2008 Sun Microsystems, Inc. All rights reserved. |
25 # Use is subject to license terms. |
25 # Use is subject to license terms. |
26 # |
|
27 # ident "%Z%%M% %I% %E% SMI" |
|
28 # |
26 # |
29 |
27 |
30 # |
28 # |
31 # Easy setup script for populating a user's ~/.hgrc |
29 # Easy setup script for populating a user's ~/.hgrc |
32 # This currently does the following: |
30 # This currently does the following: |
114 fi |
112 fi |
115 |
113 |
116 if getent hosts sunweb.central.sun.com >/dev/null; then |
114 if getent hosts sunweb.central.sun.com >/dev/null; then |
117 # on SWAN |
115 # on SWAN |
118 echo "Detected SWAN connection" |
116 echo "Detected SWAN connection" |
|
117 ON_SWAN=1 |
119 ldapemail='preferredrfc822recipient' |
118 ldapemail='preferredrfc822recipient' |
120 ldapquery="uid=$login $ldapemail" |
119 ldapquery="uid=$login $ldapemail" |
121 ldapcmd="$LDAPCLIENT -1 -h sun-ds -b dc=sun,dc=com $ldapquery" |
120 ldapcmd="$LDAPCLIENT -1 -h sun-ds -b dc=sun,dc=com $ldapquery" |
122 if [[ -z "$email" ]]; then |
121 if [[ -z "$email" ]]; then |
123 echo "Looking up e-mail address in LDAP" |
122 echo "Looking up e-mail address in LDAP" |
161 |
160 |
162 [email] |
161 [email] |
163 from=$email |
162 from=$email |
164 |
163 |
165 [paths] |
164 [paths] |
166 onnv-gate=ssh://[email protected]/hg/onnv/onnv-gate |
165 EOF |
167 |
166 |
|
167 if [[ -n $ON_SWAN ]]; then |
|
168 cat <<EOF >> $HGRC |
|
169 onnv-gate=ssh://onnv.sfbay.sun.com//export/onnv-gate |
|
170 onnv-clone=ssh://onnv.sfbay.sun.com//export/onnv-clone |
|
171 onnv-closed=ssh://onnv.sfbay.sun.com//export/onnv-gate/usr/closed |
|
172 onnv-closed-clone=ssh://onnv.sfbay.sun.com//export/onnv-clone/usr/closed |
|
173 |
|
174 EOF |
|
175 else |
|
176 cat <<EOF >> $HGRC |
|
177 onnv-gate=ssh://[email protected]//hg/onnv/onnv-gate |
|
178 |
|
179 EOF |
|
180 fi |
|
181 |
|
182 cat <<EOF >> $HGRC |
168 [merge-tools] |
183 [merge-tools] |
169 filemerge.gui=True |
184 filemerge.gui=True |
170 filemerge.args=-a \$base \$local \$other \$output |
185 filemerge.args=-a \$base \$local \$other \$output |
171 filemerge.priority=1 |
186 filemerge.priority=1 |
172 |
187 |