Click to See Complete Forum and Search --> : Why isn't an empty directory empty


GeoffreyN
01-22-2001, 07:44 AM
Running Mandrake 7.2 and have a directory /var/tmp/mozilla which contained a lot of font files after unpacking a tar file. I have now deleted them and to all appearances have an empty directory. When I tried to remove the directory, I got the message "Directory is not empty" so did an ls -a which produced
"./ ../ .directory". The first two are obvious but what is .directory, why is it there, and how can I get rid of it?
I went through the same routine a while ago when I was running MDK 7.0 and the directory was removed without any problem - I can't understand why 7.2 is different.
Any help greatly appreciated.

Pierre Lambion
01-22-2001, 07:46 AM
.directory might be a sub-directory. Try cd to it.
Or you can rm -rf /var/tmp/mozilla .


P.

GeoffreyN
01-22-2001, 08:12 AM
Well, I could'nt cd to it but have got rid of /var/tmp/mozilla with rm -rf etc. Thanks for your help but I am still puzzled by .directory. It was not visible in Konqueror or a plain ls, only ls -a. Very odd.

§ilhouette
01-22-2001, 10:25 AM
anything that begins with a '.' is considered hidden. when you issue an 'ls' command you are only viewing visible files. certain applications will create a directory beginning with a '.' and store configuration files in them (or other stuff that the average user should probably not have to modify). only when you use the flag '-a' with the 'ls' command will you be able to see *all* the files.