in reply to Need to delete empty directories.
Here is a technique I use in one of my module tests for removing the directory 'test' and anything below:
In case you are wondering about 1 while unlink, check out the node.find( { bydepth => 1, wanted => sub { if (-d $_) { rmdir $_; } else { 1 while unlink $_; } }, }, 'test') if -d 'test'; rmdir 'test';
--
I'm Not Just Another Perl Hacker
|
|---|