http://qs1969.pair.com?node_id=737557


in reply to Re: #!/usr/bin/perl vs. -*- perl -*-
in thread #!/usr/bin/perl vs. -*- perl -*-

Further to the excellent response from Tux, I tend to use the form #!/usr/bin/env perl which pulls the version of perl from your environment - this is handier if, as I have, you one, or other, or both, of the following situations...

The above is, of course, moot if you have to run on Windoze, where all sorts of other problems come into play e.g. as you suggest, the shebang line is ignored etc. hence work-rounds have to be used e.g. batch files containing the full perl script (incl. the shebang line) together with the -x CLI option (see perlrun).

A user level that continues to overstate my experience :-))