Re: Confused with File::Find

2017-06-24 Thread Andrew Solomon
Here's a small tweak to your initial script which goes some way toward shedding light on what was going wrong: #!/usr/bin/env perl use strict; use warnings; use File::Find; use feature 'say'; my $d = './one'; find sub { return if -f; say $File::Find::name; say

Re: Confused with File::Find

2017-06-24 Thread Harry Putnam
shlo...@shlomifish.org (Shlomi Fish) writes: > $File::Find::dir is the containing directory of the path item (= the > dirname in http://perldoc.perl.org/File/Basename.html ). Finally, > note that File::Find has OK, I guess I follow that. As you see in my reply to Andrew S, I kind of fumbled my

Re: Confused with File::Find

2017-06-24 Thread Harry Putnam
and...@geekuni.com (Andrew Solomon) writes: > Hi Harry > > What do you want your code to do? > Devise a simple test script the counts the number of directories in a hierarchy (This is building toward a more complex script in the end). But taking small steps in an effort to really understand what

Re: Confused with File::Find

2017-06-24 Thread Shlomi Fish
Hi Harry! On Fri, 23 Jun 2017 16:56:13 -0400 Harry Putnam wrote: > Trying for a better understand of using File::Find, butI'm missing > something pretty basic I think > > First: The directory structure in this test: > > ./one/tst.pl > two/tst.pl > three/tst.pl >

Re: Confused with File::Find

2017-06-24 Thread Andrew Solomon
Hi Harry What do you want your code to do? Andrew On Fri, Jun 23, 2017 at 9:56 PM, Harry Putnam wrote: > Trying for a better understand of using File::Find, butI'm missing > something pretty basic I think > > First: The directory structure in this test: > > ./one/tst.pl >