Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.1 6/24/83; site pegasus.UUCP Path: utzoo!watmath!clyde!burl!ulysses!mhuxr!mhuxt!houxm!ihnp4!pegasus!naiman From: naiman@pegasus.UUCP (Ephrayim J. Naiman) Newsgroups: net.unix Subject: Re: Setting variables for a running process Message-ID: <2345@pegasus.UUCP> Date: Fri, 24-May-85 12:25:15 EDT Article-I.D.: pegasus.2345 Posted: Fri May 24 12:25:15 1985 Date-Received: Sat, 25-May-85 08:10:34 EDT References: <10893@brl-tgr.ARPA> Organization: AT&T Information Systems, Lincroft NJ Lines: 29 > For example, I get on a terminal not my usual one, forget to do a > TERM type setting, and then run "send", our message-sending routine > which is part of the mmdf mail system we use here. I compose the > message and then want to use "vi" to edit it. When I run "vi", the > screen display is all messed up because the TERM type is wrong. > I can :q out of vi, and use ed instead, which is what I do, but I > wonder if there is something I can do at that point to reset my > terminal type without saving the text data, aborting "send", and > then resetting and starting over? That is, terminate the mangled "vi", > do that resets the terminal type to the correct one, and > then restart "vi" on the message text? (I would hope that there is some > generic method to do this -- I'm not looking for specific help regarding > this particular local mail tool.) As you've probably gathered by now you can't reset your TERM variable in the current process. However, in vi there IS a way to change your terminal type. The way to do it is to go into ex, change it and go back into vi. The commands are : Q (put's you in ex) set term=term_name vi (put's you in vi) -- ==> Ephrayim J. Naiman @ AT&T Information Systems Laboratories (201) 576-6259 Paths: [ihnp4, allegra, mtuxo, maxvax, cbosgd, lzmi, ...]!pegasus!naiman