Re: Here is my Perl "skeleton" (starter) script (what do you use?)



John Bokma <john@xxxxxxxxxxxxxxx> wrote:
> usenet@xxxxxxxxxxxxxxx wrote:
>> Matija Papec wrote:
>>> You have much room for improvements on your "skeleton"; that is, if
>>> you're into finding a better ways/practices.
>>
>> I'm always looking for improvements. But I thought my script was
>> pretty good (most of it was taken straight from the perldocs of the
>> various modules I'm using). However, I would be very interested to
>> know of any specific suggestions you have to improve it.
>
> A skeleton I used was:
>
> #!/usr/bin/perl
>
> use strict;
> use warnings;
>
> but I put it in the closet :-)

abbr #p #!/usr/bin/perl

use strict;
use warnings;


in my .exrc file.

Axel
.



Relevant Pages

  • Re: A script to flag commonly misused words
    ... is preferable in general as it allows you to scope warnings. ... use strict; ... I first wrote a script to extract the words to flag from your ... I discovered that at least one of the expressions you ...
    (comp.lang.perl.misc)
  • Re: [PATCH] Speed up "make headers_*"
    ... 'use strict' and 'use warnings' is recommended. ... The parentheses are not needed for most of the built-in functions. ... More or less the same comments would apply to the next script as well. ...
    (Linux-Kernel)
  • Re: Regular Expression and file editing.
    ... Goksie wrote: ... If i run the script, the changes could not be effected bcos the files is ... use warnings; ... use strict; ...
    (perl.beginners)
  • Re: Pipe input over several scripts
    ... The problem is that script c is not getting the input. ... use strict; ... use warnings; ... buffer where script_c can get it. ...
    (comp.lang.perl.misc)
  • Re: Counting column delimiters per row in a text file
    ... Then parse (see the parse method) ... This can't be more than 20 lines or so including use strict and use ... Put the data in the __DATA__ section of your script. ... use warnings; ...
    (comp.lang.perl.misc)