Date: Tue, 26 Apr 2016 09:33:31 -0453.75 From: "William A. Mahaffey III" <wam@hiwaay.net> Cc: questions@freebsd.org Subject: Re: deleting /tmp files from crontab Message-ID: <a2cc7de5-6a77-e0a1-c356-e33e1ca9ad85@hiwaay.net> In-Reply-To: <20160426141301.GA62352@skytracker.ca> References: <20160426123012.GA57555@skytracker.ca> <571F63B3.4040803@gmail.com> <20160426141301.GA62352@skytracker.ca>
next in thread | previous in thread | raw e-mail | index | archive | help
On 04/26/16 09:19, David Banning wrote: > On Tue, Apr 26, 2016 at 02:48:51PM +0200, Michael Schuster wrote: >> On 26/04/16 14:30, David Banning wrote: >>> I am attempting to delete my .spamassassin files from my /tmp directory >>> >>> putting a command in my crontab; >>> >>> find /tmp/.spam* -mmin +360 -delete >> the find syntax looks strange (assuming this is straight 'find', not >> somthing crontab-specific); normally, I'd expect to see >> >> # find /tmp -name '.spam*' -mmin +360 -delete > That seems to delete the files, but not the directories starting in .spam* > > Reviewing the find man page, it appears the -delete implementation will > not work unless the directory is empty. Still looking for solutions here. Perhaps a 2nd invocation replacing '-delete' w/ '-exec \rm -rf {} +' ? -- William A. Mahaffey III ---------------------------------------------------------------------- "The M1 Garand is without doubt the finest implement of war ever devised by man." -- Gen. George S. Patton Jr.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?a2cc7de5-6a77-e0a1-c356-e33e1ca9ad85>