Summary
Gets all directories matching the specified pattern.
Syntax
[CakeMethodAlias]
[CakeAliasCategory("Directories")]
public static DirectoryPathCollection GetDirectories(this ICakeContext context, GlobPattern pattern, GlobberSettings settings)
Examples
Func<IFileSystemInfo, bool> exclude_node_modules =
fileSystemInfo => !fileSystemInfo.Path.FullPath.EndsWith(
"node_modules", StringComparison.OrdinalIgnoreCase);
var directories = GetDirectories("./src/**/obj/*", new GlobberSettings { Predicate = exclude_node_modules });
foreach(var directory in directories)
{
Information("Directory: {0}", directory);
}
Attributes
Parameters
Return Value