From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: <96079336919420.tru64-unix-managers.marc@archive.invalid> From: Cyndi Smith Date: Tue, 15 Feb 2000 17:47:08 +0000 To: tru64-unix-managers Subject: SUMMARY Auto-empty of CDE trash? X-MARC-Message: https://marc.info/?l=tru64-unix-managers&m=96079336919420 Thanks for everyone's help. I got three replies giving quite different potential solutions. The one I chose was From: "Freesmeyer, Mary" According to the book - create a file ~/.dt/sessions/sessionexit You should be able to put rm ~/Trash/* in that file. Insure that it has execute permissions. Mary I actually created ~/.dt/sessions/sessionexit containing the following: rm -f ~/.dt/Trash/* rm -f ~/.dt/Trash/.[a-z]* touch ~/.dt/Trash/.trashinfo which seems to work. I will now place such a file in each user's .dt directory. I just need to add that to my newaccount creation script, I guess. Other suggestions were: From: "Sean O'Connell" Is this the dt trashcan or the advfs trashcan? If it is the latter, xdm lets you run stuff in TakeConsole (which is exec'd on close of the xdm session). From a quick read, it looks like /usr/dt/config/Xreset is the equivalent. According to the typical dire warnings... I decided to avoid anything involving "dire warnings" ... From: "Scott Mutchler" I have not worked much with CDE but I remember a trick that went something like this: In your user's startup file (eg .profile), you can trap signal 0 (ie a logout) and perform some action when that event happens. Perhaps you could call a script to rm any leftover stuff you want to get rid of, or just clear the file, etc. Syntax, if I recall, is something like: trap 'rm filename' 0 Good luck Scott Mutchler Gordon Food Service/Marketplace I decided to avoid this because some of our users monkey with their .profiles and they might modify this in an unfortunate manner... Thanks for all the suggestions! Cyndi -- -Cyndi Smith Programmer Analyst III, Biomathematics -cyn@odin.mdacc.tmc.edu M.D. Anderson Cancer Center, Houston, Texas -phone: (713) 794-4938 fax: (713) 792-4262