Subject: Re: bug#16287: RFE rm "-x" == "--one-file-system"

From: Bernhard Voelker <[email-masked]>
Date: Mon, 30 Dec 2013 10:42:42 +0100

On 12/30/2013 02:17 AM, Linda Walsh wrote:
> Bernhard Voelker wrote:
>> However, although -x is indeed a common option of several
>> programs, we are reluctant to add new short options.
>>
>> I'd only consider doing so for compatibility reasons
>
> 	I'm looking at compatibility reasons with
> coreutil programs that recurse directories.

> All of the other *recursive* core utils that have the ability to
> isolate action to 1 file system have -x.
> 
> chmod, cp, df, ls, dir, du
> 
> find uses "-xdev"
> tar uses -x
> secure rm (srm) uses -x
> mkzftree uses -x (makes a zisofs)
> 
> primarily was thinking about consistency in the coreutils --

Stop, stop, stop.
This is not an 'which program has a -x option?' contest.

Some of the above programs don't even have a -x or
--one-file-system option (e.g. chmod) while others have
a -x option, but that don't stand for --one-file-system
(e.g. df and ls); and finally, some are not even part of
coreutils package (e.g. tar).

To stick to your argument - "compatibility" among coreutils programs -
here is a little list:

* These coreutils programs have a -x option (with mostly a
  completely different meaning, of course):

    cp df du ls od shred stty test

* These coreutils programs have a --recursive option:

    chcon chgrp chmod chown cp ls rm

* These coreutils programs have a --one-file-system option:

    cp du rm

So even with that more accurate table, this is a quite weak
argument to add "rm -x".

What I meant (and I thought that would be obvious): I wanted
to know if there are other 'rm' implementations which have
the -x option - the *BSDs, Solaris, etc.

Have a nice day,
Berny