Skip to content
Prev 41322 / 63424 Next

should dir(all=TRUE) return "." and ".."?

On Fri, 23 Sep 2011, Martin Maechler wrote:

            
It was intentional.  The authors of that part wanted it that way, the 
original author of list.files (aka dir) wanted this the way it was 
before include.dirs was added.
Someone would need to check for back-compatibility though: 
list.files() has been around for a long time.

There are lots of odder things about list.files(), for example that it 
lists directories with recursive=FALSE and not with recursive=TRUE. 
So is a directory a file or not?