home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1994 January / usenetsourcesnewsgroupsinfomagicjanuary1994.iso / sources / misc / volume3 / can2 / emptytrash < prev    next >
Encoding:
Text File  |  1989-02-03  |  472 b   |  16 lines

  1. : /bin/sh
  2.  
  3. # EMPTYTRASH 
  4. # Executed from root crontab file every night.
  5. # It finds all files in all users .traschan directories and gets
  6. # rid of any file that has not been accessed or modified for more
  7. # than 7 days.  Note:  this works in conjunction with can.  can
  8. # changes modifies the access time for a file when it moves the  
  9. # file to the user's .trashcan diretory.
  10.  
  11. find /cd441/*/.trashcan -atime +7 -print | while read FILE
  12. do 
  13. #       echo $FILE
  14.     rm $FILE
  15. done
  16.