Path: utzoo!utgpu!water!watmath!clyde!rutgers!mit-eddie!bloom-beacon!think!ames!hc!hi!kurt From: kurt@hi.unm.edu (Kurt Zeilenga) Newsgroups: comp.unix.questions Subject: Re: Fun with ignoreeof Message-ID: <23236@hi.unm.edu> Date: 24 Jan 88 17:07:01 GMT References: <2248@tekcrl.TEK.COM> Reply-To: kurt@hi.unm.edu (Kurt Zeilenga) Organization: U. of New Mexico, Albuquerque Lines: 27 In article <2248@tekcrl.TEK.COM> eirik@crl.TEK.COM (Eirik Fuller) writes: >This is not intended to do much beyond amuse, but ... > >I have the following two lines in .cshrc: > >alias exit 'echo "Use ^D to exit"' >alias logout 'echo "Use ^D to logout"' > >They are there only as a joke, but they got me thinking. Suppose I >also say "set ignoreeof". How do I logout? No fair using unset or >unalias or alias -- they give any number of obvious two-liners. Can >I do it with a one-liner? (Using ";" is cheating too :-). kill -9 $$ >My first impulse was "\exit" or "\logout". No dice, since a leading >\ to undo aliases also undoes builtins. This soon led me to exec; >the first quiet one I tried was "exec true"; it worked. > >So how about it? Any other solutions, that don't use alias, unalias, >unset, exec, or source? Don't waste any time on this, as it is of no >more importance than it seems. Flames about shell preference will be >quietly ignored. :-) -- Kurt (zeilenga@hc.dspo.gov)