I need to find and delete all folders within C:\parent which contain only one file. The folder structure is flat (no subfolders):
C:\parent\folder1\file1 C:\parent\folder1\file2 C:\parent\folder2\file1 <-- Delete folder2 C:\parent\folder3\file1 <-- Delete folder3 C:\parent\folder4\file1 C:\parent\folder1\file2 C:\parent\folder1\file3
Anyone can recommend a program / script to do this? As I'm not very familiar with terminal commands, it would be great to get some kind of walkthrough..