.TH ttytype "" "" Command
.PC "Select a default terminal type for a port"
.B ttytype
.PP
The command
.B ttytype
selects a default terminal type for a given port.
.PP
The default terminal types are recorded in file
.BR /etc/ttytype .
You must edit this file to ensure that the default terminal types
are described correctly.
The following gives a example version of
.BR /etc/ttytype :
.DM
	ansipc    console    The COHERENT console
	adm3a     com1l      The old Kaypro II
	vt100     com2r      Remote logins
.DE
.PP
The first string gives the type of terminal.
This string must name a terminal that is recognized by
.B termcap
and
.B terminfo .
The second string gives the device with which this terminal type is linked.
The \fBconsole\fR device should always be linked to terminal type
.BR ansipc .
Other devices can be linked to the type of terminal most often used on them;
on the above example, the user has a Kaypro II that is wired into his \*(CO
system via a local serial port.
.B ttytype
ignores all strings after the first two in each line, so you can add
comments to each entry, as in the above example.
.PP
You can use
.B ttytype
to set a terminal type automatically at login time.
To do so, edit the file
.B /etc/profile
and replace the line
.DM
	export TERM=ansipc
.DE
.PP
with the command:
.DM
	export TERM=\(ga/usr/bin/ttytype\(ga
.DE
.SH Files
\fB/etc/ttytype\fR \(em File of default terminal types
.SH "See Also"
.Xr "commands," commands
.Xr "termcap," termcap
.Xr "terminfo" terminfo
