+if [[ "$oldest" != "0" ]]; then
+ now=`date +%s`
+ timeago=$(( ( $now - $oldest ) / 60 + 180 ))
+ if [[ "$timeago" -lt "180" ]]; then
+ echo "Oldest is in the future, something is wrong."
+ else
+ if [[ "$timeago" -le "720" ]]; then
+ timeago=720
+ fi
+
+ find -L <%= @archive_dir %> -mmin +$timeago -print0 | xargs -0r rm
+ fi
+fi
+
+diskfree=`df --output=pcent <%= @archive_dir %> | tail -n 1 | sed s:[^0-9.]::g`