# .logout # # This file is executed whenever you log out from the computer # # Eric Myers University of Michigan Physics Dept. # @(#) $Revision: 4.0 $ + $Date: 2003/01/26 16:07:49 $ + $Author: myers $ ###################################################################### ## Trash Compaction: set COMPRESS=gzip if ( -d ~/.garbage.bin ) then set Z='(.gz$|.Z$|.z$)' # regexp matching all compressed file ext's set X="`/bin/ls -A1 ~/.garbage.bin | egrep -v '$Z' `" if ( ${#X} > 0 ) then echo "compressing the trash..." ( cd ~/.garbage.bin ; $COMPRESS -f $X & ) endif endif ## Show unread e-mail: if ($?mail) then if ( -e $mail && ! -z $mail ) then echo 'You have unread mail...' from echo " " endif endif ## Make sure old mail is hidden! if ( -e ~/mbox ) chmod go-rwx ~/mbox if ( -e ~/Mail ) chmod go-rwx ~/Mail if ( -e ~/RMAIL ) chmod go-rwx ~/RMAIL ## Record logout if ~/.activity file exists: if ( -f ~/.activity && -w ~/.activity ) then echo "+logout $HOST `who am i`" >> ~/.activity endif ## Say g'night, Gracie... if ( ! $?USER ) setenv USER "`who am i`" if ( ! $?NAME ) setenv NAME "$USER" echo "Logout from `hostname` at `date` " echo "$ORGANIZATION" echo " " echo "Goodbye, $NAME . . ." echo " " echo " " if ( -e /usr/games/fortune ) /usr/games/fortune if ( -e /usr/um/bin/fortune ) /usr/um/bin/fortune echo " " sleep 3 stty 0 exit 0 ##