Path: utzoo!news-server.csri.toronto.edu!cs.utexas.edu!uunet!beartrk!ceilidh!dnichols From: dnichols@ceilidh.beartrack.com (DoN Nichols) Newsgroups: comp.sys.3b1 Subject: Re: stty: : Not a typewriter Message-ID: <1991Mar8.000152.2910@ceilidh.beartrack.com> Date: 8 Mar 91 00:01:52 GMT References: <1495@das13.snide.com> Organization: D and D Data, Vienna, VA. Lines: 36 In article <1495@das13.snide.com> dave@das13.snide.com (Dave Snyder) writes: >That's the error message I get while doing various things on my machine. > >For example: when in vi, I like to read in the current date & time by typing >"!!date". What that does is fork a shell, run date and the output of date is >read into the buffer (see example below). > >Wed Mar 6 07:31:23 EST 1991 > > >Now for some strange reason, this is what I get when I type "!!date". > >stty: : Not a typewriter >Wed Mar 6 07:38:47 EST 1991 Have you made any changes recently to your '.kshrc' (if using /bin/ksh) or '.profile'? Especially the '.kshrc'. If I remember correctly, the '.profile' is sourced only at logon, while the '.kshrc' is sourced whenever a subshell is started, such as for running a command while in your editor. What appears to be happening is that your '.kshrc' is trying to set some terminal options whenever you start a new shell, (the kill char, etc), and stty looks at standard output, determines it is a pipe (to your buffer in vi), and it can't do ioctl's on a pipe which are intended for a tty, therefore the 'not a typewriter' error message. The stty operations are better done in your '.profile'. Maybe you can get away with redirecting it to /dev/tty, but I wouldn't bet on it. Good Luck DoN. -- Donald Nichols (DoN.) | Voice (Days): (703) 664-1585 D&D Data | Voice (Eves): (703) 938-4564 Disclaimer: from here - None | Email: --- Black Holes are where God is dividing by zero ---