shebang - What is the significance of -T or -w in #!/usr/bin/perl? -


i googled #!/usr/bin/perl, not find satisfactory answer. know it’s pretty basic thing, still, explain me significance of #!/usr/bin/perl in perl? moreover, -w or -t signify in #!/usr/bin/perl? newbie perl, please patient.

the #! commonly called "shebang" , tells computer how run script. you'll see lots of shell-scripts #!/bin/sh or #!/bin/bash.

so, /usr/bin/perl perl interpreter , run , given file execute.

the rest of line options perl. "-t" tainting (it means input marked "not trusted" until check it's format). "-w" turns warnings on.

you can find out more running perldoc perlrun (perldoc perl's documentation reader, might installed, might in own package).

for scripts write recommend starting them with:

#!/usr/bin/perl use warnings; use strict; 

this turns on lots of warnings , checks - useful while learning (i'm still learning , i've been using perl more 10 years now).


Comments

Popular posts from this blog

c# - SVN Error : "svnadmin: E205000: Too many arguments" -

c# - Copy ObservableCollection to another ObservableCollection -

All overlapping substrings matching a java regex -