CPANPLUS::Config(3pm)
π CPANPLUS::Config β the manual, but make it make sense π
okay bestie, welcome to CPANPLUS::Config β the (3pm) page that's literally just the vibe bible for CPANPLUS config π. This module is where all the defaults and heuristics live for how CPANPLUS behaves. It's giving "settings drawer, but documented". Let's get into it. π¦
β¨ NAME β¨
CPANPLUS::Config β configuration defaults and heuristics for CPANPLUS. no cap, that's the whole thing. π
πΈ SYNOPSIS πΈ
like, here's how you actually touch this thing:
### conf object via CPANPLUS::Backend;
$cb = CPANPLUS::Backend->new;
$conf = $cb->configure_object;
### or as a standalone object
$conf = CPANPLUS::Configure->new;
### values in 'conf' section
$verbose = $conf->get_conf( 'verbose' );
$conf->set_conf( verbose => 1 );
### values in 'program' section
$editor = $conf->get_program( 'editor' );
$conf->set_program( editor => '/bin/vi' );
two ways in: borrow the conf object off a CPANPLUS::Backend, or spin up a CPANPLUS::Configure on its own. then get_conf/set_conf for the conf section, and get_program/set_program for the program section. periodt. β¨
π«Ά DESCRIPTION π«Ά
This module contains defaults and heuristics for configuration information for CPANPLUS. So if you wanna change any of these values, please go read the docs in CPANPLUS::Configure β that's the one with the actual how-to. π
Below you'll find a list of configuration types and keys, and their meaning. buckle up, it's a long list, but I promise it slaps. π
π CONFIGURATION π
π« Section 'conf' π«
hostsβ an array ref stuffed with hosts entries that get queried for packages. here's what one lil entry looks like:
{ 'scheme' => 'ftp',
'path' => '/pub/CPAN/',
'host' => 'ftp.cpan.org'
},
allow_build_interactivityβ boolean flag, says whetherperl Makefile.PLand friends run interactively or not. defaults totrue.allow_unknown_prereqsβ boolean flag meaning unresolvable prereqs are acceptable. Iftrue, then only warnings will be issued (that was the behaviour before 0.9114) when a module is unresolvable from any of our sources (CPAN and/orcustom_sources). Iffalse, then an unresolvable prereq will fail during thepreparestage of distribution installation. Defaults totrue. πbaseβ the directory CPANPLUS keeps all its build and state information in. Defaults to~/.cpanplus. IfFile::HomeDiris available, that will be used to work out yourHOMEdirectory. This may be overridden by setting thePERL5_CPANPLUS_HOMEenvironment variable, seeCPANPLUS::Config::HomeEnvfor more details. πbuildflagsβ any flags to be passed toperl Build.PL. Seeperldoc Module::Buildfor details. Defaults to an empty string.cpantestβ boolean flag, says whether or not to mail test results of module installations tohttp://testers.cpan.org. Defaults tofalse.cpantest_mxβ string holding an explicit mailserver to use when sending out emails forhttp://testers.cpan.org. An empty string will use your system settings. Defaults to an empty string. π§debugβ boolean flag to enable or disable extensive debugging information. Defaults tofalse.dist_typeβ default distribution type to use when building packages. Seecpan2distorCPANPLUS::Distfor details. An empty string will not use any package building software. Defaults to an empty string.emailβ email address to use for anonymous ftp access and as the "from" address when sending emails. Defaults to anexample.comaddress.enable_custom_sourcesβ boolean flag, says whether custom sources should be enabled or not. See theCUSTOM MODULE SOURCESinCPANPLUS::Backendfor details on how to use them.
Defaults to true.
extractdirβ string with the directory where fetched archives should be extracted. An empty string will use a directory under yourbasedirectory. Defaults to an empty string.fetchdirβ string with the directory where fetched archives should be stored. An empty string will use a directory under yourbasedirectory. Defaults to an empty string.flushβ boolean, says whether build failures, cache dirs etc should be flushed after every operation or not. Defaults totrue.forceβ boolean, says whether files should be forcefully overwritten if they exist, modules should be installed when they fail tests, etc. Defaults tofalse. π (yes it's as chaotic as it sounds)histfileβ a string containing the history filename of the CPANPLUS readline instance.libβ an array ref holding directories to be added to@INCwhen CPANPLUS starts up. Defaults to an empty array reference.makeflagsβ a string holding flags that will be passed to themakeprogram when invoked. Defaults to an empty string.makemakerflagsβ a string holding flags that will be passed toperl Makefile.PLwhen invoked. Defaults to an empty string.md5β a boolean saying whether or not sha256 checks should be done when an archive is fetched. Defaults totrueif you haveDigest::SHAinstalled,falseotherwise.no_updateβ a boolean saying whether or notCPANPLUS's source files should be updated or not. Defaults tofalse.passiveβ a boolean saying whether or not to use passive ftp connections. Defaults totrue.prefer_binβ a boolean saying whether or not to prefer command line programs over perl modules. Defaults tofalseunless you do not haveCompress::Zlibinstalled (because that would mean we could not extract.tar.gzfiles). ποΈprefer_makefileβ a boolean saying whether or not to prefer aMakefile.PLover aBuild.PLfile if both are present. Defaults totrue, unless the perl version is at least 5.10.1 or appropriate versions ofModule::BuildandCPANPLUS::Dist::Buildare available.prereqsβ a digit saying what to do when a package you're installing has a prerequisite. the options are:0β Do not install1β Install2β Ask3β Ignore (dangerous, install will probably fail!)
The default is to ask.
shellβ a string holding the shell class you wish to start up when startingCPANPLUSin interactive mode.
Defaults to CPANPLUS::Shell::Default, the default CPANPLUS shell.
show_startup_tipβ a boolean saying whether or not to show start up tips in the interactive shell. Defaults totrue.signatureβ a boolean saying whether or not to check signatures if packages are signed. Defaults totrueif you havegpgorCrypt::OpenPGPinstalled,falseotherwise. πskiptestβ a boolean saying whether or not to skip tests when installing modules. Defaults tofalse.storableβ a boolean saying whether or not to useStorableto write compiled source file information to disk. This makes for faster startup and look up times, but takes extra diskspace. Defaults totrueif you haveStorableinstalled andfalseif you don't.timeoutβ digit indicating the time before a fetch request times out (in seconds). Defaults to300. β³verboseβ a boolean saying whether or notCPANPLUSruns in verbose mode. Defaults totrueif you have the environment variablePERL5_CPANPLUS_VERBOSEset to true,falseotherwise.
It is recommended you run with verbose enabled, but it is disabled for historical reasons.
write_install_logβ a boolean saying whether or not to write install logs after installing a module using the interactive shell. Defaults totrue.source_engineβ class to use as the source engine, which is generally a subclass ofCPANPLUS::Internals::Source. Defaults toCPANPLUS::Internals::Source::Memory.cpantest_reporter_argsβ a hashref of key => value pairs that are passed to the constructor ofTest::Reporter. If you'd want to enable TLS for example, you'd set it to:
{ transport => 'Net::SMTP::TLS',
transport_args => [ User => 'Joe', Password => '123' ],
}
π¦ Section 'program' π¦
editorβ a string holding the path to your editor of choice. Defaults to your$ENV{EDITOR},$ENV{VISUAL},viorpicoprograms, in that order. βοΈmakeβ a string holding the path to yourmakebinary. Looks for themakeprogram used to build perl or failing that, amakein your path.pagerβ a string holding the path to your pager of choice. Defaults to your$ENV{PAGER},lessormoreprograms, in that order.shellβ a string holding the path to your login shell of choice. Defaults to your$ENV{SHELL}setting, or$ENV{COMSPEC}on Windows.sudoβ a string holding the path to yoursudobinary if your install path requires super user permissions. Looks forsudoin your path, or remains empty if you do not require super user permissions to install.perlwrapperβ DEPRECATED
A string holding the path to the cpanp-run-perl utility bundled with CPANPLUS, which is used to enable autoflushing in spawned processes. β οΈ
π BUG REPORTS π
Please report bugs or other issues to <bug-cpanplus@rt.cpan.org<gt>.
(not me copying that email character for character, that's literally what it says π)
π AUTHOR π
This module by Jos Boumans <kane@cpan.org>. π«‘
π COPYRIGHT π
The CPAN++ interface (of which this module is a part of) is copyright (c) 2001 - 2007, 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.
π SEE ALSO π
CPANPLUS::BackendCPANPLUS::Configure::SetupCPANPLUS::Configure
and that's a wrap, bestie π«Ά this page ships with perl v5.40.1, dated 2025-03-01, and it's part of the User Contributed Perl Documentation for CPANPLUS::Config(3pm). go configure something iconic. β¨ππ
π¦ where this page comes from
- debian trixie: libcpanplus-perl 0.9916-1 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu resolute: libcpanplus-perl 0.9916-1 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu stonking: libcpanplus-perl 0.9916-1 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms