4

除了一个(隐藏的)子目录之外,删除目录全部内容的最佳方法是什么?谢谢!

4

1 回答 1

7
<Target Name="DeleteMe">
   <ItemGroup>
      <DeleteMe
         Include="$(PathRoot)/FolderToDelete/**/*.*"
         Exclude="$(PathRoot)/FolderToDelete/DoNotDeleteThisHiddenFolder/**/*.*"
         />
   </ItemGroup>
   <Delete Files="@(DeleteMe)" />
</Target>
于 2012-04-04T21:45:07.410 回答