instance method
Dir#children
() -> ::Array[::String]
children → array
dir.c
View on GitHub ↗
static VALUE
dir_collect_children(VALUE dir)
{
VALUE ary = rb_ary_new();
dir_each_entry(dir, rb_ary_push, ary, TRUE);
return ary;
}
Returns an array of the entry names in self except for '.' and '..':
Example
dir = Dir.new('/example') dir.children # => ["config.h", "lib", "main.rb"]