[NTLUG:Discuss] Yet Another Scripting Request

Rick Renshaw bofh69 at yahoo.com
Thu Aug 28 20:51:59 CDT 2008


--- On Thu, 8/28/08, Daniel Hauck <daniel at yacg.com> wrote:

> From: Daniel Hauck <daniel at yacg.com>
> Subject: [NTLUG:Discuss] Yet Another Scripting Request
> To: "NTLUG Discussion List" <discuss at ntlug.org>
> Date: Thursday, August 28, 2008, 4:46 PM
> Objective:
> 
> Write a script that will read through a directory and
> subdirectories and 
> identify all files older than X days (let's just say 5
> days if it helps) 
> and delete them.

find /directory/to/search/ -ctime +5 -exec rm -f \{\} \;




      



More information about the Discuss mailing list