On 25/02/2012 19:24, Manfred Lotz wrote:
Hi all,
I had a look at remove_tree from File::Path.

Let us say I have a directory: ./a/b/c/d

When I do

remove_tree('./a',
        {
           verbose =>  1
        });

I get the following messages:

rmdir d
rmdir c
rmdir b
rmdir ./a


Is there a way to get nice messages like this:

rmdir ./a/b/c/d
rmdir ./a/b/c
rmdir ./a/b
rmdir ./a'

?

Or is there another module which does give nicer messages when deleting
a directory tree?

Hi Manfred

This seems an odd choice on the part of the authors, especially as the
verbose output for *unlinked* files shows the complete path.

All I can suggest is making your own version of the module, simply by
editing all occurrences of "$root" to "$canon" on every line that
contains "if $arg->{verbose}". This is a low-risk strategy as it doesn't
chnage the functionality of the module.

Cheers,

Rob

--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/


Reply via email to