in reply to Re: How do I search for a specific directory on a remote PC?
in thread How do I search for a specific directory on a remote PC?
See perldoc File::Find for how to use $File::Find::dir and $_ in the wanted function.use File::Find; find ( ref to function, start path(s) ) e.g.: use File::Find; find (\&wanted, '.'); sub wanted { print($File::Find::dir, "/$_\n") if -d $_; } or, just as good: use File::Find; find ( sub {print($File::Find::dir, "/$_\n") if -d $_}, '.');
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Re: How do I search for a specific directory on a remote PC?
by Anonymous Monk on Jan 05, 2002 at 00:40 UTC |