Re: /etc/daily: use find -delete

2020-10-08 Thread Denis Fondras
On Thu, Oct 08, 2020 at 05:32:15AM -0600, Todd C. Miller wrote: > We can use find's built-in -delete primary to remove old /tmp files > and directories. This is somewhat less error-prone than execing > rm or rmdir. > OK denis@ > - todd > > Index: etc/daily >

/etc/daily: use find -delete

2020-10-08 Thread Todd C . Miller
We can use find's built-in -delete primary to remove old /tmp files and directories. This is somewhat less error-prone than execing rm or rmdir. - todd Index: etc/daily === RCS file: /cvs/src/etc/daily,v retrieving revision 1.93

Re: find -delete

2017-01-13 Thread Dmitrij D. Czarkoff
"Ted Unangst" wrote: > This option is not posix (not like that's stopped find accumulating a > dozen extensions), but it is in gnu and freebsd (for 20 years). it's > also somewhat popular among sysadmins and blogs, etc. and perhaps most > importantly, it nicely solves one of

Re: find -delete

2017-01-07 Thread Mark Kettenis
> Date: Sat, 7 Jan 2017 13:15:05 + > From: Stuart Henderson > > On 2017/01/07 11:32, Marc Espie wrote: > > On Tue, Jan 03, 2017 at 11:15:39PM +0100, Mark Kettenis wrote: > > > > From: "Ted Unangst" > > > > Date: Tue, 03 Jan 2017 16:39:48 -0500 > >

Re: find -delete

2017-01-07 Thread Stuart Henderson
On 2017/01/07 11:32, Marc Espie wrote: > On Tue, Jan 03, 2017 at 11:15:39PM +0100, Mark Kettenis wrote: > > > From: "Ted Unangst" > > > Date: Tue, 03 Jan 2017 16:39:48 -0500 > > > > > > I copied this straight from freebsd. Not fixed, but feel free to correct > > > as > > >

Re: find -delete

2017-01-07 Thread Marc Espie
On Tue, Jan 03, 2017 at 11:15:39PM +0100, Mark Kettenis wrote: > > From: "Ted Unangst" > > Date: Tue, 03 Jan 2017 16:39:48 -0500 > > > > I copied this straight from freebsd. Not fixed, but feel free to correct as > > desired. > > > > This adds a third example showing

Re: find -delete

2017-01-03 Thread Ted Unangst
Mark Kettenis wrote: > I really think we should not encourage unportable code like that by > giving an example in our manual page. That's fair. > I'm even tempted to say that you should leave the "-exec rm {} \;" > example alone. The + here only works because rm(1) accepts multiple > file

Re: find -delete

2017-01-03 Thread Theo de Raadt
>> From: "Ted Unangst" >> Date: Tue, 03 Jan 2017 16:39:48 -0500 >> >> I copied this straight from freebsd. Not fixed, but feel free to correct as >> desired. >> >> This adds a third example showing -delete, mentioning that it's not standard, >> but also hinting that it may

Re: find -delete

2017-01-03 Thread Mark Kettenis
> From: "Ted Unangst" > Date: Tue, 03 Jan 2017 16:39:48 -0500 > > I copied this straight from freebsd. Not fixed, but feel free to correct as > desired. > > This adds a third example showing -delete, mentioning that it's not standard, > but also hinting that it may work

Re: find -delete

2017-01-03 Thread Ted Unangst
Jason McIntyre wrote: > no opinion on the addition, but if there is a better way to write the > examples that are there, i think you should take the time to do so. i'd > also slightly prefer we show the more traditional way to do it, though i > appreciate that might not make a ton of sense for

Re: find -delete

2017-01-03 Thread Todd C. Miller
OK millert@ for the code. I'll defer to jmc@ on the man page bits. - todd

Re: find -delete

2017-01-03 Thread Jason McIntyre
On Tue, Jan 03, 2017 at 12:15:02AM -0500, Ted Unangst wrote: > This option is not posix (not like that's stopped find accumulating a dozen > extensions), but it is in gnu and freebsd (for 20 years). it's also somewhat > popular among sysadmins and blogs, etc. and perhaps most importantly, it >

find -delete

2017-01-02 Thread Ted Unangst
This option is not posix (not like that's stopped find accumulating a dozen extensions), but it is in gnu and freebsd (for 20 years). it's also somewhat popular among sysadmins and blogs, etc. and perhaps most importantly, it nicely solves one of the more troublesome caveats of find (which the man