如果具有以下结构:
F:\ParentA\FindMe
F:\ParentA\DoNotFindMe
F:\ParentB\FindMe
F:\ParentB\SomethingElse
因此,在每个父文件夹(其中很多)中,我都有子文件夹,每次我想要查找的的正好一个具有相同的名称。< / p>
我考虑过 循环是另一种选择,但我一直在寻找一个时尚/快速的解决方案.. $children = Get-ChildItem "F:\*\FindMe"
但仅会返回第一个(在大写 parentA 中)但正如我说的那样需要每个父文件夹。