coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Wishing rmdir had a prompt


From: Lady Aleena
Subject: Re: Wishing rmdir had a prompt
Date: Wed, 11 Sep 2019 04:29:49 -0400
User-agent: Roundcube Webmail/1.0.7

I thank everyone who got involved with my little wish. I did not mean for it to explode like this. I am entirely comfortable letting the whole idea drop since there appears to be little to no support for it. I was just an idle wish that crossed my mind that I wanted to share.

Again, thank you for reading it and taking the time to respond.

Have a very nice day!
Lady Aleena

On 2019-09-02 11:22, Bernhard Voelker wrote:
On 9/2/19 10:03 AM, Sami Kerola wrote:
[...] I don't see any problem adding --interactive long
only option.

a) Bloat:
Apart from the --parents option, rmdir(1) is just a simple
wrapper around rmdir(2).
Just recently I've been asked (off-list) why src/true.c needs
to have 80+ lines while 3 lines would be enough.

b) Alternatives:
The case is trivial enough to have some little prompt wrapper around it.
E.g. a bit contrived but works:
  $ xargs -p rmdir DIR </dev/null
  rmdir DIR ?...y

c) As Kaz already wrote: it's easy enough to re-create an empty directory
which has been deleted accidentally.

d) My personal opinion: I'm not in favor of those "do you really want to XYZ?" questions - especially in the case one just explicitly told the tool exactly
to "do XYZ".  Similarly, one could argument why not to add it to sleep,
kill, cat, and so on.

Have a nice day,
Berny




reply via email to

[Prev in Thread] Current Thread [Next in Thread]