PERL

From The System Administrator Zone

What directories does Perl search for it included modules?

To print out Perl's include path.
perl -e 'print join("\n", @INC),"\n";'

How do you install Perl modules using CPAN?

To get an interactive CPAN prompt
perl -MCPAN -e shell

To install some module without interaction
perl -MCPAN -e 'install Bundle::libnet'

Perl 4 / Perl 5 differences

The one that bit me is that any @ characters in a string must now be escaped with a backslash.


Perl Documentation

The manuals provided with every perl installation are a very valuable source for information.

$ perldoc perl # lists manuals.

Search if a manual exists for debugging:

$ perldoc perl | grep deb
           [ -cw ] [ -d[:debugger] ] [ -D[number/list] ]
           perldebtut          Perl debugging tutorial
           perldebug           Perl debugging
           perldebguts         Perl debugging guts and tips
       o   enhanced debugger and interactive Perl environment, with integrated
           Described in perldebtut, perldebug and perldebguts.

Get help on the built-in functions:

$ perldoc perlfunc

Looking something up in the FAQ

$ perldoc -q SEARCHTERM