GNU bug report logs - #27632
rm -f fais on directories

Previous Next

Package: coreutils;

Reported by: graham <at> tasam.com

Date: Mon, 10 Jul 2017 00:04:01 UTC

Severity: normal

Tags: notabug

Done: Tino Calancha <tino.calancha <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


Message #8 received at 27632 <at> debbugs.gnu.org (full text, mbox):

From: Tino Calancha <tino.calancha <at> gmail.com>
To: Marv Graham <graham <at> tasam.com>
Cc: 27632 <at> debbugs.gnu.org
Subject: Re: bug#27632: rm -f fais on directories
Date: Mon, 10 Jul 2017 12:19:46 +0900
Marv Graham <graham <at> tasam.com> writes:

> This is VERY unexpected behavior! An 'rm -f' command has (for my experience in the last 30 years) removed anything.
>
> What;'s the problem with rm on ubuntu?
Flag -f won't delete directories.
To remove anything, you'd use: rm -rf

Use flag -r (or -R) to delete directories.  If you prefer
delete _empty_ directories but preserve non-empty dirs, then use
flag -d.


From the 'rm' manual:

     -r, -R, --recursive
          remove directories and their contents recursively

     -d, --dir
          remove empty directories





This bug report was last modified 7 years and 311 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.