Wondering how would one go about writing a script that:
Counts the number of files in a directory.
If that number is greater than a specified number N, delete the oldest file in the directory.
For bonus feelings of good will: Only included .zip files in the count/delete.
find
, manwc
, manls
– Nils May 14 '12 at 21:00