in reply to Re: asterisk use
in thread asterisk use
This first example uses the full variable name to find all instances of mail.log.* in the current directory and pushes the results on @files.
use File::Find; find( sub { push @files, $File::Find::name if -f && /mail.log.*/ }, '. +');
This second example does the same thing only using the glob'd version of the variable name.
use File::Find; use vars qw/*name/; *name = *File::Find::name; find( sub { push @files, $name if -f && /mail.log.*/ }, '.');
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: asterisk use
by smist (Acolyte) on Jan 11, 2007 at 14:19 UTC | |
by Hofmator (Curate) on Jan 11, 2007 at 14:38 UTC | |
|
Re^3: asterisk use
by smist (Acolyte) on Jan 11, 2007 at 13:38 UTC |