From mboxrd@z Thu Jan 1 00:00:00 1970 From: urgrue Subject: simple scripting question Date: Mon, 27 Jan 2003 11:58:28 +0200 Sender: linux-admin-owner@vger.kernel.org Message-ID: <20030127095828.GA23742@fede2.tumsan.fi> Mime-Version: 1.0 Content-Transfer-Encoding: 7BIT Return-path: Content-Disposition: inline List-Id: Content-Type: text/plain; charset="us-ascii"; To: linux-admin@vger.kernel.org i have several dirs and i want to delete the ones that are older than 60 days. currently im doing it like this: find /path/backups-* -type d -mtime +60 | xargs rm -r but i dont want to go through the CONTENTS of the dirs and delete every individual file that is older than 60d. i want to either delete or not delete the whole dir depending on its timestamp. but i only know of find that accepts something as spiffy as -mtime +60, and i cant find any options for it like "--non-recursive". any suggestions? basically this is for removing outdated backups.