Re: delete directory

From: houghi (houghi_at_houghi.org.invalid)
Date: 04/07/05


Date: Thu, 7 Apr 2005 13:51:58 -0000

mjt wrote:
> (Houston CAPCOM <null@null.org>) scribbled:
>
>> I am trying to use rmdir to delete a directory that is not empty and I
>> cant do it. How do I delete a directory that has files in it?
>
>
> ... rm -rf <dirname>
>

I always now use `rm <dirname> -rf` as it gives me 1 second more to
realize what directory I am deleting. Especially handy if you work with
[TAB] a lot. `rm <letter>[TAB] -rf[ENTER]` or `rm -rf
<letter>[TAB][ENTER]` Withe the second you will delete a directory that
you perhaps wich not to delete, because you are in the wrong directory.

I happendd to delete `/sbin` instead of `/usr/home/houghi/tmp/sbin` that
way. Yeah, I was still root after checkinstall and typed `/sb[TAB]`
instead of `sb[TAB]`

-- 
houghi		Please to not toppost			http://houghi.org
>
You tried, and you failed, so the lesson is, never try. - Homer J. Simpson.


Relevant Pages

  • Re: delete directory
    ... On 2005-04-07, Houston CAPCOM wrote: ... > I am trying to use rmdir to delete a directory that is not empty and I ... > cant do it. ...
    (alt.os.linux.suse)
  • Re: Bonnie++ Burps on XFS
    ... Anything in your system log? ... I had filesystem corruption and needed ran xfs_repair. ... rmdir: `658616481': Directory not empty ...
    (Linux-Kernel)
  • [RFC][PATCH 4/4] cgroup-memcg fix frequent EBUSY at rmdir
    ... When trying following test under memcg. ... You'll see -EBUSY at rmdir very often. ... or false error code if the cgroup has ...
    (Linux-Kernel)
  • Re: Removing corrupted directory
    ... I can toggle the bits with ... I'm not sure if rmdir behaves any differently than rm -r but have ... > The command rmdir is just a safety command, only removing empty ...
    (comp.sys.mac.system)
  • Re: If/Then that changes a fields backcolor
    ... i cant make it take into consideration if the field is empty. ... looking at formatting some date fields so that as time nears the deadline, ... "Jeff Boyce" wrote: ...
    (microsoft.public.access.reports)