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
|
#! /bin/sh
## Copyright (C) 2004 Aaron Bentley
##
## See the file "COPYING" for further information about
## the copyright and warranty status of this work.
#prevent infinite filter loops!
unset ABAFILTER
export ABAFILTER
. "$abadir/aba-lib"
# executes the command ("$@" are the arguments after the command name)
cmd_exec()
{
if aba_supports_option file-find silent; then
silent="--silent"
fi
if [ -z "$VIEWDIFF" ]; then
echo '$VIEWDIFF is unset' >&2
exit 1
fi
loc=$(tla file-find $silent $1 $2)
if [ -z "$loc" ]; then
echo "Cannot find library revision for $1"
exit 1
fi
$VIEWDIFF $loc $1
}
# one-liner description for aba help
cmd_desc()
{
aba_desc $(basename $0) "Uses \$VIEWDIFF to compare file revisions"
}
# short help for aba command -h, --help
cmd_help()
{
cat <<EOH
Uses \$VIEWDIFF to compare file revisions
usage: $abaname $(basename $0) file [revision]
Uses \$VIEWDIFF to compare two file revisions.
EOH
}
# extended help for aba command -H or aba help command
cmd_ext_help()
{
cat <<EOH
EOH
}
aba_run "$@"
# arch-tag: vimdiff by Aaron Bentley (16:41 Apr 30 2004)
|