in reply to find "x" quantity newest files in a dir
perl -e '@sorted = sort { -M $a <=> -M $b } </path/*>; unlink foreach +@sorted[10..$#sorted]'
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: find "x" quantity newest files in a dir
by merlyn (Sage) on Jun 27, 2001 at 18:10 UTC | |
|
Re: Re: find "x" quantity newest files in a dir
by runrig (Abbot) on Jun 27, 2001 at 18:39 UTC |