using find to compare file mtime with another file's mtime
Hello,
I have a simple backup script that is cron`ed to run nightly. Since I am tarballing over 80 gigs I am limited on the amount of backups I can keep on disk. I would like to keep about two backup tarballs on disk and delete the oldest of the three. So, WED night backup runs, THURS night backup runs, then FRI night backup runs and WED night file gets deleted. I'm not sure how to compare the mtimes of the 3 files so that the oldest can be determined and deleted. Any ideas? Thanks in advance. |
Code:
/usr/bin/stat -c %y bashrc Code:
/usr/bin/stat --help |
All times are GMT -5. The time now is 05:49 PM. |