I am trying to delete a ton of directories located under C:\Windows\Temp.
There are a bunch of directories that start off with:
- chef[DATE]-[4_NUMBERS]-[A_STRING_OF CHARACTERS]
under the C:\Windows\Temp.
I am trying to use the 'directory resource' to remove all of the chef created directories but having a problem.
I know the following code works to delete one directory, but need to know how to make it delete any directory that starts with "chef."
directory "C:\\Windows\\Temp\\chef20210226-1000-1clkm9o" do recursive true action :delete end
Thank you in advance!