Path: utzoo!attcan!uunet!seismo!sundc!pitstop!sun!decwrl!ucbvax!AERO4.LARC.NASA.GOV!blbates From: blbates@AERO4.LARC.NASA.GOV (Bates TAD/HRNAB ms294 x2601) Newsgroups: comp.sys.sgi Subject: Re: Killing mex Message-ID: <8811172250.AA11990@aero4.larc.nasa.gov> Date: 17 Nov 88 19:50:28 GMT Sender: daemon@ucbvax.BERKELEY.EDU Organization: The Internet Lines: 27 Here is a .logout file that I use: clear ismex if($status == 1 && `tty` == '/dev/console') then kill -9 `ps x | grep 'clock$' | awk '{print $1}' ` kill -9 `ps x | grep 'w[0-9]' | grep 'csh (csh)' | awk '{print $1}' ` kill -9 `ps x | grep 'mex$' | awk '{print $1}' ` endif if( `tty` == '/dev/console' ) then gclear endif date First it clears the text screen, then it checks to see if mex is running and if you are on the console. I usually have the clock running, so it kills that, next it kills each window (VERY! IMPORTANT). Then it kills mex. If you are on the console it clears the graphics screen. The if's are very important, if you don't have them and you log off a remote terminal it messes up the console, especially if someone is using it. The order is also important. If you kill mex with out killing the other windows first it messes things up. If you have any questions, let me know. P.S. You must compile ismex in the gifts directory. /usr/people/gifts/mextools/tools/ismex