in reply to Re: Modifying %ENV From The Shebang Line
in thread Modifying %ENV From The Shebang Line

That's not true. Perl needs it or else it will run the #! line when it notices "perl" isn't present in it.
  • Comment on Re^2: Modifying %ENV From The Shebang Line

Replies are listed 'Best First'.
Re^3: Modifying %ENV From The Shebang Line
by educated_foo (Vicar) on Dec 17, 2007 at 23:59 UTC
    I stand corrected. I had forgotten (or maybe never read) that part. The full details in perlrun are much too long to quote, but here's one relevant passage:
    If the #! line does not contain the word "perl", the program named after the #! is executed instead of the Perl interpreter. This is slightly bizarre, but it helps people on machines that don't do #!, because they can tell a program that their SHELL is /usr/bin/perl, and Perl will then dispatch the program to the correct interpreter for them.