[sf-perl] dynamic #! line
extasia at extasia.org
Mon Mar 23 18:55:17 PDT 2009
if you're in a unix environment, you'll have at least /bin/sh
available (hopefully /bin/bash too). could you call a shell program
which will set the shebang line and then call the resulting program
with all args?
in the shell program you could do useful things, like look for
different perl executables, perhaps md5sum them, check whether they're
in system directories, check when they were last modified, whether
they're group or world writeable, and perhaps take intelligent action
if no "suitable" perl's are found.
On Mon, Mar 23, 2009 at 5:36 PM, Matthew Lanier <matt at lanier.org> wrote:
> i'm in a situation where I may need to set #! on a perl script at run time
> via the environment. I know that's technically possible, but am unsure what
> hidden gotchas may result. Any thoughts on that?
Live in a world of your own, but always welcome visitors.
More information about the SanFrancisco-pm