|
Hi
Try a "ls -t |tail -n +16" - it should give all files in a directory except the 15 newest files. (ls -t means sort by time, the "tail -n +16" means skip the 15 first lines.
So a
rm $(ls -t |tail -n +16)
would do the trick I think.
Hope this helps,
Guttorm.
Last edited by Guttorm; 06-21-2006 at 07:22 AM.
|