Line | |
---|
1 | .TH TGET 1
|
---|
2 | .SH NAME
|
---|
3 | tget \- get termcap values
|
---|
4 | .SH SYNOPSIS
|
---|
5 | .B tget
|
---|
6 | .RB [ \-flag
|
---|
7 | .IR id ]
|
---|
8 | .RB [ \-num
|
---|
9 | .IR id ]
|
---|
10 | .RB [ \-str
|
---|
11 | .IR id ]
|
---|
12 | .RB [ \-goto
|
---|
13 | .IR "col line" ]
|
---|
14 | .RB [[ \-echo ]
|
---|
15 | .IR string ]
|
---|
16 | .SH DESCRIPTION
|
---|
17 | .B Tget
|
---|
18 | allows shell scripts access to the
|
---|
19 | .BR termcap (3)
|
---|
20 | functions. Flags, numbers and strings can be queried from the termcap
|
---|
21 | database under the entry denoted by the environment variable
|
---|
22 | .BR $TERM .
|
---|
23 | .SH OPTIONS
|
---|
24 | .TP
|
---|
25 | .BI \-flag " id"
|
---|
26 | Set the exit status to zero if the flag
|
---|
27 | .I id
|
---|
28 | is set. All other options except
|
---|
29 | .B \-echo
|
---|
30 | set the exit status to
|
---|
31 | .I id
|
---|
32 | being available or not. The last option sets the final exit code.
|
---|
33 | .TP
|
---|
34 | .BI \-num " id"
|
---|
35 | Print the value of the numeric variable
|
---|
36 | .IR id .
|
---|
37 | .TP
|
---|
38 | .BI \-str " id"
|
---|
39 | Print the value of the string variable
|
---|
40 | .IR id .
|
---|
41 | .TP
|
---|
42 | .BI \-goto " col line"
|
---|
43 | Generates instructions to go to the given column and line if the
|
---|
44 | .B cm
|
---|
45 | capability exists.
|
---|
46 | .TP
|
---|
47 | .BI \-echo " string"
|
---|
48 | Prints
|
---|
49 | .IR string .
|
---|
50 | Any other argument that does not start with a dash is also printed.
|
---|
51 | .SH EXAMPLE
|
---|
52 | Try this:
|
---|
53 | .B "tget -str so 'Reverse Video' -str se"
|
---|
54 | .SH ENVIRONMENT
|
---|
55 | .TP 15n
|
---|
56 | .B TERM
|
---|
57 | Terminal type.
|
---|
58 | .TP
|
---|
59 | .B TERMCAP
|
---|
60 | Path to the termcap database, by default /etc/termcap:/usr/etc/termcap.
|
---|
61 | .SH "SEE ALSO"
|
---|
62 | .BR termcap (3).
|
---|
63 | .SH DIAGNOSTICS
|
---|
64 | .B Tget
|
---|
65 | will fail immediately with a descriptive message if the termcap entry
|
---|
66 | can't be found.
|
---|
67 | .SH AUTHOR
|
---|
68 | Kees J. Bot (kjb@cs.vu.nl)
|
---|
Note:
See
TracBrowser
for help on using the repository browser.