File: run-tic.sh

package info (click to toggle)
xterm 235-2
  • links: PTS, VCS
  • area: main
  • in suites: lenny
  • size: 3,780 kB
  • ctags: 4,528
  • sloc: ansic: 48,756; sh: 3,793; perl: 1,036; makefile: 406
file content (27 lines) | stat: -rwxr-xr-x 527 bytes parent folder | download
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
#!/bin/sh
# $XTermId: run-tic.sh,v 1.3 2007/06/17 15:30:03 tom Exp $
#
# Run tic, either using ncurses' extension feature or filtering out harmless
# messages for the extensions which are otherwise ignored by other versions of
# tic.

TMP=run-tic$$.log
VER=`tic -V 2>/dev/null`
OPT=

case .$VER in
.ncurses*)
	OPT="-x"
	;;
esac

echo "** tic $OPT" "$@"
tic $OPT "$@" 2>$TMP
RET=$?

fgrep -v 'Unknown Capability' $TMP | \
fgrep -v 'Capability is not recognized:' | \
fgrep -v 'tic: Warning near line ' >&2
rm -f $TMP

exit $RET