gri6507 has asked for the wisdom of the Perl Monks concerning the following question:
and $script is a user specified argument (a la $ARGV[0]). When I run this directly through the interpreter, my pwd is the directory where I am currently located, so that the relative path to $ARGV[0] is correct. However, when I run the pp'd EXE, the pwd is the PAR directory and the relative path to $ARGV[0] is no longer correct. How can I reconcile that?unless (my $return = do $script) { warn "could not parse $script: $@" if $@; warn "could not pull in $script: $!" unless defined $return; warn "could not execute $script" unless $return; }
As always, thanks in advance!
P.S. I know the risks of do(tainted_input), but because this tool is intended for internal distribution only, safety is not a concern.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Par::Packer and paths
by Anonymous Monk on Oct 27, 2011 at 18:39 UTC | |
by gri6507 (Deacon) on Oct 27, 2011 at 18:51 UTC |