In your code, you are checking whether you have a file (-f). Maybe you want to do something there if you have a directory (-d)?
Note that you get the directory likely before all the files, so you might need to remember that you want to unlink rmdir a directory after you've successfully moved all the files.
Update Laurent_R noted the difference between unlink and rmdir.
In reply to Re: File::Find help
by Corion
in thread File::Find help
by colox
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |