Date: Tue, 26 Apr 2016 16:30:00 +0200 From: Timo Buhrmester <fstd.lkml@gmail.com> To: David Banning <david+dated+1462111984.5033c3@skytracker.ca> Cc: questions@freebsd.org Subject: Re: deleting /tmp files from crontab Message-ID: <20160426143000.GA18932@grapefruit.localdomain> 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
> > # 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. A common idiom is ``find ... -print0 | xargs -0 rm -r''. Note that -print0 and xargs -0 aren't POSIX, but I'm not aware of implementations lacking those.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20160426143000.GA18932>