File::path the option keep_root => 1 does not seem to work

--000e0cd56d8ef3f51904a1425322
Content-Type: text/plain; charset=ISO-8859-1

hi

File::path the option keep_root => 1 does not seem to work for me

use File::Path;

rmtree( '/temp/auto', { verbose =>1 , keep_root => 1} );

it throw me the output

unlink /temp/auto/test6 unlink /temp/auto/test5 unlink /temp/auto/test4
rmdir /temp/auto

the option keep_root => 1 should keep the root path ??


--
Regards
Agnello D'souza

--000e0cd56d8ef3f51904a1425322--
Agnello George [ Di, 19 April 2011 11:42 ] [ ID #2058375 ]

Re: File::path the option keep_root => 1 does not seem to work

On 19/04/2011 10:42, Agnello George wrote:
>
> File::path the option keep_root => 1 does not seem to work for me
>
> use File::Path;
>
> rmtree( '/temp/auto', { verbose =>1 , keep_root => 1} );
>
> it throw me the output
>
> unlink /temp/auto/test6 unlink /temp/auto/test5 unlink /temp/auto/test4
> rmdir /temp/auto
>
> the option keep_root => 1 should keep the root path ??

You are right. I can't fault the code you have posted.

There must be something else wrong. Please show us the entire program?

Rob

--
To unsubscribe, e-mail: beginners-unsubscribe [at] perl.org
For additional commands, e-mail: beginners-help [at] perl.org
http://learn.perl.org/
Rob Dixon [ Do, 21 April 2011 20:17 ] [ ID #2058521 ]
Perl » gmane.comp.lang.perl.beginners » File::path the option keep_root => 1 does not seem to work

Vorheriges Thema: time format conversion
Nächstes Thema: Changing XML Tag Value in Perl