Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!seismo!lll-crg!nike!sri-spam!parcvax!hplabs!tektronix!tekgen!tektools!jerryp From: jerryp@tektools.UUCP (Jerry Peek) Newsgroups: net.unix Subject: Re: setenv problem in C-shell (and "tset") Message-ID: <1446@tektools.UUCP> Date: Wed, 3-Sep-86 03:24:11 EDT Article-I.D.: tektools.1446 Posted: Wed Sep 3 03:24:11 1986 Date-Received: Wed, 3-Sep-86 21:08:38 EDT References: <3454@brl-smoke.ARPA> <1427@tektools.UUCP> Reply-To: jerryp@tektools.UUCP (Jerry Peek) Organization: Tektronix, Inc., Beaverton, OR. Lines: 52 In article <1427@tektools.UUCP>, net.unix-wizards, I followed up to a followup article about "tset": > In article <3454@brl-smoke.ARPA> DU>@brl-smoke.ARPA writes: > > You're probably going to hear this a lot... > > and this is probably the 200th article that'll be posted, but I hate to see > errors posted to the net without corrections... > > > You should do: > > > > set noglob; eval `tset ... ` > > Not just that! Don't forget to do "unset noglob" -- otherwise, the shell > won't expand filename wildcard characters afterwards. Do this: > > set noglob; eval `tset ...`; unset noglob I shouldn't have used the word "errors" to describe the earlier posting -- maybe the author has a different version of "tset" that automatically outputs a "unset noglob". My apologies if this is true. Since then, I've noticed that under 4.3BSD and C-shell, "tset" outputs both the "set noglob" and "unset noglob" commands automatically. Here's a demonstration (since I didn't use the "eval `tset`" business, you see the output of "tset" on the screen; it doesn't change the current settings in the shell): Script started on Wed Sep 3 00:00:34 1986 % tset -sQ '?Enter terminal type' TERM = (Enter terminal type) 4023 set noglob; setenv TERM 4023 ; setenv TERMCAP 'X4|tek4023|4023:so=^_H:se=^_@:cm=\034%r%+\040%+\040:nd=\t:bs:am:cl=4\E^L:co#80:li#24:up=1000UP:'; unset noglob; % !! tset -sQ '?Enter terminal type' TERM = (Enter terminal type) xyz Type xyz unknown TERM = (unknown) ^C % ^D script done on Wed Sep 3 00:02:39 1986 The second "tset" commandline shows another new feature under 4.3: if you give a terminal type that isn't in your termcap file, the 4.3BSD "tset" will print "Type xxx unknown" and ask again. Pre-4.3 versions wouldn't ask again; they just quit without doing anything. --Jerry Peek, Tektronix, Inc. US Mail: MS 74-900, P.O. Box 500, Beaverton, OR 97077 uucp: {allegra,decvax,hplabs,ihnp4,ucbvax}!tektronix!tektools!jerryp CS,ARPAnet: jerryp%tektools@tektronix.csnet Phone: +1 503 627-1603