I have Perl script and need to determine the full path and filename of the script during execution. I discovered that depending on how you call the script $0 va
$0
I think the module you're looking for is FindBin:
#!/usr/bin/perl use FindBin; $0 = "stealth"; print "The actual path to this is: $FindBin::Bin/$FindBin::Script\n";