From 33c7397f5b8d7b0320feb9105b052f4ba975efdc Mon Sep 17 00:00:00 2001 From: hno <> Date: Sat, 25 Jun 2005 03:11:08 +0000 Subject: [PATCH] Fix snapshot procedure to be less sensitive on file dates when removing old copies, relying on the file names instead. --- mksnapshot-cron.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mksnapshot-cron.sh b/mksnapshot-cron.sh index b931be0e07..00abe20fa2 100755 --- a/mksnapshot-cron.sh +++ b/mksnapshot-cron.sh @@ -42,7 +42,7 @@ make_snapshot() ln -s $file $dst/squid-$ver.snapshot$type # cleanup old snapshots - ls -t $dst/*-[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]$type | tail +$save | xargs rm -f + ls $dst/*-[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]$type | sort -r -t- +2 | tail +$save | xargs rm -f done # update web page -- 2.47.2