I have a Delete Files task in VS TS Build, whose goal is to delete one file at the root of a Source Folder. The minimatch script I have does indeed delete the file correctly, but it also traverses all of the sub folders of the Source Folder directory also looking for a match, which wastes build time. I just want to delete this one file and stop the task.
Here is what I have (simplified for this example):
How can I accomplish this?
This is the expected behavior for Delete Files
task. This task find all files and then match the patterns by default.
As an alternative, you could use Powershell
task to write a script to delete the file:
Remove-Item –path c:\temp\MyFileName.txt