NAME
CPANPLUS - Command-line access to the CPAN interface
NOTICE
CPANPLUS will appear in Perl core in version 5.10, under an as-yet undetermined name. CPAN.pm will be deprecated. CPANPLUS is not a drop-in replacement for CPAN.pm.
A shell interface which resembles the shell aspects (and not the programming interface) of CPAN.pm is available. Refer to CPANPLUS::Shell for information on switching to the Classic shell.
SYNOPSIS
Command line:
/perl/bin/cpanp
perl -MCPANPLUS -e 'shell'
perl5.6.1 -MCPANPLUS -e 'install Net::SMTP'
perl -MCPANPLUS -e 'fetch /K/KA/KANE/Acme-POE-Knee-1.10.zip'
perl5.00503 -MCPANPLUS -e 'get /K/KA/KANE/Acme-POE-Knee-1.10.zip'
Note that one CPANPLUS installation can be used for multiple versions of Perl. If no version is specified, the Perl version used to install CPANPLUS will be used.
Scripts:
use CPANPLUS;
# This use is not recommended; use
# CPANPLUS::Backend instead!
install('Net::SMTP');
get('Acme::POE::Knee');
DESCRIPTION
CPANPLUS provides command-line access to the CPAN interface. Three functions, fetch, install and shell are imported in to your namespace. get--an alias for fetch--is also provided.
Although CPANPLUS can also be used within scripts, it is highly recommended that you use CPANPLUS::Backend in such situations. In addition to providing an OO interface, CPANPLUS::Backend is more efficient than CPANPLUS for multiple operations. CPANPLUS is provided primarily for the command-line, in order to be backwards compatible with CPAN.pm.
The first time you run CPANPLUS you should be prompted to adjust your settings, if you haven't already done so. Your settings will determine treatment of dependencies, handling of errors, and so on.
FUNCTIONS
install(NAME)
This function requires the full name of the module, which is case sensitive. The module name can also be provided as a fully qualified file name, beginning with a /, relative to the /authors/id directory on a CPAN mirror.
It will download, extract and install the module.
fetch(NAME)
Like install, fetch needs the full name of a module or the fully qualified file name, and is case sensitive.
It will download the specified module to the current directory.
get(NAME)
Get is provided as an alias for fetch for compatibility with CPAN.pm.
shell
Shell starts the default CPAN shell. You can also start the shell by using the cpanp
command, which will be installed in your perl bin.
See CPANPLUS::Shell::Default for instructions on using the default shell. Note that if you have changed your default shell in your configuration, that shell will be used instead. If for some reason there was an error with your specified shell, you will be given the default shell.
You may also optionally specify another shell to use for this invocation (which is a good way to test other shells): perl -MCPANPLUS -e 'shell Classic'
Shells are only designed to be used on the command-line; use of shells for scripting is discouraged and completely unsupported.
AUTHORS
This module by Jos Boumans <kane@cpan.org>.
This pod text by Ann Barcomb <kudra@cpan.org>.
COPYRIGHT
The CPAN++ interface (of which this module is a part of) is copyright (c) 2001, 2002 Jos Boumans <kane@cpan.org>. All rights reserved.
This library is free software; you may redistribute and/or modify it under the same terms as Perl itself.
ACKNOWLEDGMENTS
Please see the AUTHORS file in the CPANPLUS distribution for a list of Credits and Contributors.
SEE ALSO
CPANPLUS::Backend, CPANPLUS::Shell::Default
CONTACT INFORMATION
General suggestions: cpanplus-info@lists.sourceforge.net
Bug reporting: cpanplus-bugs@lists.sourceforge.net
Development list: cpanplus-devel@lists.sourceforge.net