/computer
CPAN Very, Very Brief Instructions
Following up on my own idea, here is an extremely brief guide the the Perl CPAN module, for people like me who can never remember exactly what to type to get it to go.
The Comprehensive Perl Archive Network is a set of mirror sites for Perl and Perl modules. If you already have Perl running and need to install a module that you just discovered you need, you can use the CPAN module, which you probably already have, to automagically download and install it.
If you know that you need Net::DNS, you could run
perl -MCPAN -e "install Net::DNS"
to install it. You’ll probably want to run it as root. If you are not sure exactly what the name of the module you are looking for is,
perl -MCPAN -e shell;
will start the interactive shell, from which you could try
i /dns/
which will show you everything available with “dns” in the name. You can then type
install Net::DNS
from the shell to install it. exit or control-D and
probably several other things will exit the interactive shell.
If you need to do anything more complex, read the real documentation. At some point CPAN will be replaced by CPANPLUS, which at this time (2003-11-20) appears to be at version 0.047. I don’t know anything about it.
category: /computer | permanent link
