1 |
On Fri, Nov 19, 2010 at 10:29 AM, Peter Humphrey |
2 |
<peter@××××××××××××××.org> wrote: |
3 |
> Hello list, |
4 |
> |
5 |
> Just to expose my ignorance again, would someone lift my blinkers |
6 |
> please? I'm recovering from an infection and my brain is stuck. |
7 |
> |
8 |
> It's time to start pruning old stuff from the website I run, which has |
9 |
> 2200 files in 200 directories. |
10 |
|
11 |
You can use -mtime option in find to return files whose modification |
12 |
time are older than X days ago. For example I have a job to delete |
13 |
files who are 48 hours old using something like: |
14 |
|
15 |
find /directoryname -mtime +1 -delete |
16 |
|
17 |
(something like that, i'm writing it from memory, refer to manpage) |