in reply to problems returning from recursive subroutine
Using proper technology, your code becomes simply:
use File::Find; finddepth sub { return if /^\./; my $new = lc $_; return if $new eq $_ or -e $new; rename $_, $new or warn "Cannot rename $File::Find::name to $File::F +ind::dir/$new: $!"; }, $ARGV[0] || ".";
-- Randal L. Schwartz, Perl hacker
Be sure to read my standard disclaimer if this is a reply.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: problems returning from recursive subroutine
by Abigail-II (Bishop) on Apr 18, 2003 at 11:43 UTC | |
by merlyn (Sage) on Apr 18, 2003 at 11:48 UTC |