The shebang line tells the terminal where to look for the Perl interpreter.
On unix:
- Code: Select all
$ ./perlScript.pl
will read the file, see the shebang line and know to execute it with the Perl interpreter found at that location. You can install Perl wherever you like.
On windows, you will normally run it with:
- Code: Select all
>perl perlScript.pl
which will automagically know to use the Perl interpreter to compile it. Of course, you CMD will need to know the Perl command which you would add to the environment vars if it isn't already there thanks to Strawberry Perl.
Of course in Unix, you can initiate it like the windows version and this will allow you to omit the shebang line.
shebang eq #!/usr/bin/Perl
As for your "storage" confusion, I'm not sure what you mean.