Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister
 
PerlMonks  

Re^2: Shebang Inside the coding ?

by ysth (Canon)
on Jan 16, 2006 at 08:09 UTC ( #523433=note: print w/ replies, xml ) Need Help??


in reply to Re: Shebang Inside the coding ?
in thread Shebang Inside the coding ?

Shebangs is meaningful only on the first 2 bytes in the first line of a file.
Not always. Perl's -x switch allows you to run a program that has other garbage before it (e.g. the program is embedded in an email message), and expects to find the #! line partway into the file. See just above http://perldoc.perl.org/perlrun.html#ENVIRONMENT.


Comment on Re^2: Shebang Inside the coding ?
Replies are listed 'Best First'.
Re^3: Shebang Inside the coding ?
by sk (Curate) on Jan 16, 2006 at 16:38 UTC
    Thanks ysth. I totally forget about that switch. Now I remember how people use to make jpeg files print JAPH but putting the shebang at the end of the jpeg file and running the jpeg file through -x. Thanks for catching this!

    cheers

    SK

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://523433]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others wandering the Monastery: (14)
As of 2015-07-31 15:53 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (279 votes), past polls