in reply to getting shell expansion to work
If you want "shell" expansion (csh to be exact), the glob function is what you want, or, if you prefer a module and saner expansion, File::Glob. I couldn't follow your description of things you tried, so I won't comment on why they failed for you. If you provide better code, possibly wrapped in <code>...</code> tags, they will be more readable for me and I can maybe tell you where you went wrong.
You seem to be unclear about where "shell expansion" happens - it does not happen within Perl but within your shell. So, if you want shell expansion Just Like Your Shell Does, you will have to call your shell and ask it to expand the pattern.
In many cases, reading the Perl documentation of the built-in functions (perlfunc) helps lots.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: getting shell expansion to work
by FunkyMonk (Bishop) on Dec 28, 2007 at 00:33 UTC | |
by eserte (Deacon) on Dec 28, 2007 at 00:53 UTC | |
by Corion (Patriarch) on Dec 28, 2007 at 08:22 UTC | |
|
Re^2: getting shell expansion to work
by perl-diddler (Chaplain) on Dec 27, 2007 at 20:50 UTC | |
by Corion (Patriarch) on Dec 27, 2007 at 22:20 UTC | |
by perl-diddler (Chaplain) on Dec 28, 2007 at 19:36 UTC |