Subject: Re: CVS commit: src/usr.bin/find
To: SODA Noriyuki <soda@sra.co.jp>
From: Perry E. Metzger <perry@piermont.com>
List: tech-userlevel
Date: 02/08/2007 08:29:04
SODA Noriyuki <soda@sra.co.jp> writes:
>>>>>> On Wed, 07 Feb 2007 12:49:33 -0500,
>       "Perry E. Metzger" <perry@piermont.com> said:
>
>>> The problem is that the -delete option is somewhat different from
>>> what you expect from the -rm option.
>
>> What do you think of as the difference?
>
> For example, "find /usr/src -rm" just doesn't work.

The man page seems to imply that find /usr/src -delete should
work. Perhaps the documentation needs to be fixed.

     -delete
             Delete found files and/or directories.  Always returns True.
             This executes from the current working directory as find recurses
             down the tree.  It will not attempt to delete a filename with a
             ``'' character in its pathname relative to ``''.  for security
             reasons.  Depth-first traversal processing is implied by this
             option.  

That doesn't really describe what is wrong with find /usr/src -delete

>>> Maybe that's the reason FreeBSD chose different option name.
>
>> I spoke to some people from FreeBSD and suggested they adopt -rm as an
>> alias -- they thought it was a good idea.
>
> But they haven't added the option yet.
> That means they decided that that is actually bad idea, doesn't it?

No, since it has been all of 24 hours, I would draw no such conclusion.

> If not, why haven't they added the -rm option yet?

Because just about no time has passed.

Anyway, this is Unix -- we don't "del file" or "delete file", we
"rm file"...

Perry