Path: utzoo!attcan!uunet!cs.utexas.edu!usc!zaphod.mps.ohio-state.edu!mips!wyse!bob From: bob@wyse.wyse.com (Bob McGowen x4312 dept208) Newsgroups: comp.unix.questions Subject: Re: Can a script check if my line is dialup? Message-ID: <2780@wyse.wyse.com> Date: 3 Jul 90 16:15:11 GMT References: <1990Jun29.050949.8906@midway.uchicago.edu> <2776@wyse.wyse.com> <3586@auspex.auspex.com> Sender: news@wyse.wyse.com Reply-To: bob@wyse.UUCP (Bob McGowen x4312 dept208) Organization: Wyse Technology Lines: 35 In article <3586@auspex.auspex.com> guy@auspex.auspex.com (Guy Harris) writes: >>tset uses the /etc/ttytype file as a database mapping terminal types to >>tty lines. > >"tset" on *some* systems *might* use "/etc/ttytype" as a database >mapping terminal types to tty lines; I've never seen any such system, >but perhaps Wyse's flavor of UNIX is one such system? Try SCO XENIX, which gives credit to UCBerkely for the tset program. The man page for XENIX references /etc/ttytype as the database file. This is also true for Wyse UNIX, as you guessed. >Some systems - e.g., 4.3BSD, and probably therefore nExt's OS, use >"/etc/ttys" (or "/etc/ttytab", if they had to keep "/etc/ttys" in the It is cetainly possible that the database file name changed somewhere in the series. The Sun system at Wyse uses the file /etc/ttytab. But I recall seeing /etc/ttytype on an older BSD UNIX, though I do not remember the version. >old format for backwards compatibility), as that table, and in the cases >I've seen it's "login", not "tset", that uses it, and sets the TERM >environment varible; "tset" just looks at that environment variable. According to the man page tset will use the environment variable for TERM if it is set. If TERM is not set for some reason (presumably some system's login commands or shells do not do this automagically) then tset would have to read the database file. This again comes from the man page, none of the systems I have access to fail to set TERM before starting the shell. Bob McGowan (standard disclaimer, these are my own ...) Product Support, Wyse Technology, San Jose, CA ..!uunet!wyse!bob bob@wyse.com