File: profile.in

package info (click to toggle)
aegis 4.24.3-3
  • links: PTS
  • area: main
  • in suites: jessie, jessie-kfreebsd, wheezy
  • size: 34,056 kB
  • ctags: 12,500
  • sloc: cpp: 178,528; sh: 79,948; makefile: 34,813; yacc: 4,610; perl: 1,499; ansic: 492; awk: 325
file content (471 lines) | stat: -rw-r--r-- 7,170 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
#
#	aegis - project change supervisor
#	Copyright (C) 1991-1996, 1999, 2001-2004, 2006-2008 Peter Miller
#
#	This program is free software; you can redistribute it and/or modify
#	it under the terms of the GNU General Public License as published by
#	the Free Software Foundation; either version 3 of the License, or
#	(at your option) any later version.
#
#	This program is distributed in the hope that it will be useful,
#	but WITHOUT ANY WARRANTY; without even the implied warranty of
#	MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
#	GNU General Public License for more details.
#
#	You should have received a copy of the GNU General Public License
#	along with this program. If not, see
#	<http://www.gnu.org/licenses/>.
#
# @configure_input@
#
# Please Note: this file will be over-written by the next installation
# of Aegis.  If you make local modifications, you will need to remember
# to make them again after the next upgrade.
#
# On Linux, or any system using bash (I think), a symlink to this file
# from /etc/profile.d/aegis.sh can be very useful.
#
if test -z "$AEGIS_PATH" -a -d $HOME/lib/aegis/.
then
	AEGIS_PATH=$HOME/lib/aegis
	export AEGIS_PATH
fi

#
# Set the AEGIS_AUTOMOUNT_POINTS environment variable to the names
# of the directories which the automounter uses to temporarily mount
# file systems.  Use with extreme caution as this distorts Aegis' idea
# of the shape of the filesystem.
#
#	/tmp_mnt is typical of Sun automounters
#	/a is the default for amd, an OpenSource automounter
#	/.automount is typical of amd on Linux
#
# The automounters need to be configured so that the path below the
# automount point is *identical* to the path without it - because all
# Aegis tries to do is remove the automount prefix *if* the file
# stat()s the same with and without it.  This is the default for the
# Sun automounter, but not typical in the examples in the amd user guide.
#
AEGIS_AUTOMOUNT_POINTS="/tmp_mnt:/a:/.automount"
export AEGIS_AUTOMOUNT_POINTS

#
# Each of the Aegis commands has its own alias.  This is essential for
# aecd, and convenient for the others.  (Splitting Aegis into many
# commands is only efficient if the target system has shared libraries,
# because the size of the common code portion usually greatly exceeds
# the size of the unique portions.)
#
# Note: while Bash uses the "function" keyword to define functions, the
# original Bourne shell does not.  Bash understands the form with out he
# "funtion" keyword, so it is omitted.
#
aeb()
{
	aegis -b "$@" -v
}
aeca()
{
	aegis -ca "$@" -v
}
aecd()
{
	ae_response="`aegis -cd "$@" -v`"
	if test -d "$ae_response"
	then
		cd "$ae_response"
	else
		echo "$ae_response"
	fi
	unset ae_response
}
aechown()
{
	aegis -chown "$@" -v
}
aeclean()
{
	aegis -clean "$@" -v
}
aeclone()
{
	aegis -clone "$@" -v
}
aecp()
{
	aegis -cp "$@" -v
}
aecpu()
{
	aegis -cpu "$@" -v
}
aed()
{
	aegis -diff "$@" -v
}
aedb()
{
	aegis -db "$@" -v
}
aedbu()
{
	aegis -dbu "$@" -v
}
aede()
{
	aegis -de "$@" -v
}
aedeu()
{
	aegis -deu "$@" -v
}
aedless()
{
	less `find . -type f \( -name "*,D" -o -name ".*,D" \) -print | sort`
}
aedmore()
{
	more `find . -type f \( -name "*,D" -o -name ".*,D" \) -print | sort`
}
aedpager()
{
        find . -type f \( -name "*,D" -o -name ".*,D" \) -print | sort | xargs sensible-pager
}
aedn()
{
	aegis -dn "$@" -v
}
aefa()
{
	aegis -fat "$@" -v
}
aeib()
{
	aegis -ib "$@" -v
}
aeibu()
{
	aegis -ibu "$@" -v
}
aeifail()
{
	aegis -ifail "$@" -v
}
aeipass()
{
	aegis -ipass "$@" -v
}
ael()
{
	aegis -l "$@" -v
}
aem()
{
	aegis -diff -only_merge "$@" -v
}
aemt()
{
        aegis -mt "$@" -v
}
aemtu()
{
        aegis -mtu "$@" -v
}
aemv()
{
	aegis -mv "$@" -v
}
aemvu()
{
	aegis -mvu "$@" -v
}
aena()
{
	aegis -na "$@" -v
}
aenbr()
{
	aegis -nbr "$@" -v
}
aenbru()
{
	aegis -nbru "$@" -v
}
aenc()
{
	aegis -nc "$@" -v
}
aencu()
{
	aegis -ncu "$@" -v
}
aend()
{
	aegis -nd "$@" -v
}
aenf()
{
	aegis -nf "$@" -v
}
aenfu()
{
	aegis -nfu "$@" -v
}
aeni()
{
	aegis -ni "$@" -v
}
aenpa()
{
	aegis -new-project-alias "$@" -v
}
aenpr()
{
	aegis -npr "$@" -v
}
aenrls()
{
	aegis -nrls "$@" -v
}
aenrv()
{
	aegis -nrv "$@" -v
}
aent()
{
	aegis -nt "$@" -v
}
aentu()
{
	aegis -ntu "$@" -v
}
aepa()
{
	aegis -pa "$@" -v
}
aepwd()
{
	aegis -Change_Directory "$@" -terse
}
aeq()
{
	aegis -q "$@" -v
}
aer()
{
	aereport "$@" -v
}
aera()
{
	aegis -ra "$@" -v
}
aerb()
{
	aegis -rb "$@" -v
}
aerbu()
{
	aegis -rbu "$@" -v
}
aerd()
{
	aegis -rd "$@" -v
}
aerfail()
{
	aegis -rfail "$@" -v
}
aeri()
{
	aegis -ri "$@" -v
}
aerm()
{
	aegis -rm "$@" -v
}
aermu()
{
	aegis -rmu "$@" -v
}
aerpass()
{
	aegis -rpass "$@" -v
}
aerpa()
{
	aegis -remove-project-alias "$@" -v
}
aerpu()
{
	aegis -rpu "$@" -v
}
aermpr()
{
	aegis -rmpr "$@" -v
}
aerrv()
{
	aegis -rrv "$@" -v
}
aet()
{
	aegis -t "$@" -v
}
aev()
{
	aegis -VERSion "$@" -v
}

ae_c()
{
	AEGIS_CHANGE="$1"
	export AEGIS_CHANGE
}
ae_p()
{
	AEGIS_PROJECT="$1"
	export AEGIS_PROJECT
}

aeunset()
{
	unset -f aeb
	unset -f ae_c
	unset -f aeca
	unset -f aecd
	unset -f aechown
	unset -f aeclean
	unset -f aeclone
	unset -f aecp
	unset -f aecpu
	unset -f aed
	unset -f aedb
	unset -f aedbu
	unset -f aede
	unset -f aedeu
	unset -f aedless
	unset -f aedmore
	unset -f aedn
	unset -f aeunset
	unset -f aeib
	unset -f aeibu
	unset -f aeifail
	unset -f aeipass
	unset -f ael
	unset -f aem
        unset -f aemt
        unset -f aemtu
        unset -f aemv
	unset -f aemvu
	unset -f aena
	unset -f aenbr
	unset -f aenbru
	unset -f aenc
	unset -f aencu
	unset -f aend
	unset -f aenf
	unset -f aenfu
	unset -f aeni
	unset -f aenpa
	unset -f aenpr
	unset -f aenrls
	unset -f aenrv
	unset -f aent
	unset -f aentu
	unset -f ae_p
	unset -f aepa
        unset -f aepwd
	unset -f aeq
	unset -f aer
	unset -f aera
        unset -f aerb
        unset -f aerbu
	unset -f aerd
	unset -f aerfail
	unset -f aeri
	unset -f aerm
	unset -f aermpr
	unset -f aermu
	unset -f aerpa
	unset -f aerpass
	unset -f aerpu
	unset -f aerrv
	unset -f aet
        unset -f aev
	unset AEGIS
	unset AEGIS_PROJECT
	unset AEGIS_CHANGE
	unset AEGIS_PATH
	unset AEGIS_AUTOMOUNT_POINTS
}

#
# Command completion is gradually being implemented for a wide range of
# arguments for many Aegis commands.
#
if [ -n "$PS1" ]
then
    case "$BASH_VERSION" in

    2.0[4-9]* | 2.[1-9]* | [3-9].* | [1-9][0-9].*)
	complete -C aecomplete \
	    aeb \
	    ae_c \
	    aeca \
	    aecd \
	    aechown \
	    aeclean \
	    aecp \
	    aecpu \
	    aed \
	    aedb \
	    aedbu \
	    aede \
	    aedeu \
	    aedn \
	    aefa \
	    aegis \
	    aeib \
	    aeibu \
	    aeifail \
	    aeipass \
	    aemt \
	    aemtu \
	    aena \
	    aencu \
	    aend \
	    aenf \
	    aenfu \
	    aeni \
	    aenrv \
	    aentu \
	    ae_p \
	    aepa \
	    aera \
	    aerb \
	    aerbu \
	    aerd \
	    aerfail \
	    aeri \
	    aerm \
	    aermu \
	    aerpass \
	    aerpu \
	    aerrv \
	    aet
	;;
    esac

    case "$ZSH_VERSION" in

    4.[2-9]* | [5-9].* | [1-9][0-9].* )
	_aegis_complete () {
	    local output
	    output=( ${(f)"$(aecomplete $words[1]  2>/dev/null)"} )
	    test $? = 0 && compadd -a output
	}
	compdef _aegis_complete -P "ae*"
	;;
    esac
fi