[std.file] dirEntries

Tobias Pankrath tobias at pankrath.net
Mon Dec 12 06:43:37 PST 2011


Hello, 

I'm struggling with std.file.dirEntries. I want iterate over every file 
below a directory, which name starts with "test_" and does not
contain a point (".").

I've tried this, but it does not work:

--
foreach(DirEntry de; dirEntries("myDir", "temp_[!.]*", SpanMode.breadth))
{
	writeln(de.name);
}
--

It also prints names of files, which names do contain points.

I can't see, what I'am doing wrong. Can anyone help?

Tobias


More information about the Digitalmars-d-learn mailing list