bug-coreutils
[Top][All Lists]
Advanced

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

bug#34700: rm refuses to remove files owned by the user, even in force m


From: L A Walsh
Subject: bug#34700: rm refuses to remove files owned by the user, even in force mode
Date: Sun, 03 Mar 2019 00:40:46 -0800
User-agent: Thunderbird

On 3/2/2019 11:31 AM, Bob Proulx wrote:
> But regardless of that it does not change the fact that the entire
> purpose of read-only directories is to prevent removing and renaming
> of files within them.
>   
----
    But not by the user owning them.  I don't remember the last time I used
chmod -w to prevent myself from deleting all the files in a directory. 
I use
it to prevent other people from removing/renaming.  If I want to
give myself "pause", I'll set them to immutable (on linux) and chmod
read-only or system on windows -- both of those give some pause to the
standard flow.  

    But read-only and owned by me, takes about an extra 1-2 seconds as
I tack sudo on the front and run right over user perms.

>   
>> I would suggest people with specific directories that inhibit deletion of
>> files inside although they should not (e.g. a "cache") to deliberatly change
>> the permissions of said directories prior to deleting files inside. Using a
>> script like the above, even without the basic mistakes in the script, is
>> quite dangerous.
>>     
Yeah...I wouldn't do it, I'd write a script that invokes the app and
clears out the cache dir when the app exits if it bothered me enough.

Much better to let the computer do the repetitive deletions.  If I do it
manually, it increases the chances of me creating a problem the more often
I do it. 

Really -- scripts are much better at handling redundant/routine matters that
turn parts of my brain off.  OTOH, some people are better at redundant
detail
and don't suffer the same problems I would.  People are different.
>   





reply via email to

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