The following works:
#! /usr/bin/perl -w use strict; foreach (glob "$ENV{HOME}/DATA/*.db") { process_file ($_); }
Please note that calling process_file() with that leading ampersand has side-effects that really surprised me when I first learnt of them.
In reply to Re: using glob to get files
by pbeckingham
in thread using glob to get files
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |