When will os.remove fail?

Frank Millman frank at chagford.com
Tue Mar 14 10:22:12 EDT 2017

"Chris Angelico"  wrote in message 
news:CAPTjJmrim9TJHfOLgynUJATx_HkVXXQ_D8YJPkX8Y32qHCzzFw at mail.gmail.com...

On Wed, Mar 15, 2017 at 12:30 AM, Jon Ribbens <jon+usenet at unequivocal.eu> 
>>> (And the rm command won't ask if you say "-f".)
>> rm does not ask before deleting. However some Linux distributions
>> take it upon themselves to put "alias rm='rm -i'" in /etc/profile.
> I have no such alias, but it still prompts.

On Fedora 22 (and for many previous versions) I have noticed that, if I log 
in as 'root', it does prompt, but if I log in as an ordinary user, it does 

If I type 'alias' at the console, it lists current aliases. 'root' shows 
exactly what Jon quoted above. 'frank' shows no alias for 'rm'.

I had a quick look to see what was setting it, but there is nothing in 
/etc/profile or in /etc/bashrc. I don't know where else to check.

Frank Millman

More information about the Python-list mailing list