XP is just a number | |
PerlMonks |
Re: How was my script launched?by Perlbotics (Archbishop) |
on Jul 20, 2008 at 18:54 UTC ( [id://698928]=note: print w/replies, xml ) | Need Help?? |
Additionally, you might get some further clues from inspecting the filename ($0) or the command line arguments (@ARGV). If your OS supports symbolic links, than aliasing your script by symlinking it might be another alternative to identify launch circumstances. E.g., if you symlink yourscript.pl to alt_name.pl and then call the latter, $0 =~ m{/alt_name\.pl$} will render true, at least under *NIX.
In Section
Seekers of Perl Wisdom
|
|