CPANPL...nfigure(3pm)
okay so bestie, you're about to read the CPANPLUS::Configure(3pm) page, and yes it lives in the User Contributed Perl Documentation corner of your manual, and yes it's giving extremely useful. pull up a chair π«Ά
πΈ NAME πΈ
CPANPLUS::Configure β the configuration situation for CPANPLUS, periodt π
β¨ SYNOPSIS β¨
$conf = CPANPLUS::Configure->new( );
$bool = $conf->can_save;
$bool = $conf->save( $where );
@opts = $conf->options( $type );
$make = $conf->get_program('make');
$verbose = $conf->set_conf( verbose => 1 );
π DESCRIPTION π
So this module is literally the one handling all the configuration issues for CPANPLUS. You can grab objects made by this module and use them to change how CPANPLUS behaves β like, you're the main character, and this is the settings panel π
If you wanna know how to actually get yourself a CPANPLUS::Configure object, go peek at the CPANPLUS::Backend documentation. it's all in there, iykyk π
π METHODS π
π $Configure = CPANPLUS::Configure->new( load_configs => BOOL )
This hands you back a brand new object, slay. But ngl, normal users will never need to call new themselves β instead you retrieve the object you want by calling a method on a CPANPLUS::Backend object. that's the vibe π«
load_configs
This one controls whether or not extra user configurations get loaded or not. Defaults to true. no cap β¨
π $bool = $Configure->init( [rescan => BOOL])
This initializes the configure using other config files, not just the default 'CPANPLUS::Config'. fancy π
It gets called from new() to load your user/system configurations.
If you pass in the rescan option, your disk gets examined again to see if there are any new config files that could be read. Defaults to false.
Returns true on success, false on failure. fr fr π
π can_save( [$config_location] )
Checks whether we can save the configuration to the file you specified. If you don't hand it a file, it defaults to your personal config.
Returns true if the file can be saved, false otherwise. π¦
π $file = $conf->save( [$package_name] )
Saves the configuration to the package name you gave it. okay so here's the tea:
- If that package is not
CPANPLUS::Config::System, it gets saved in your.cpanplusdirectory. - Otherwise, it'll be attempted to be saved in the system wide directory. (On Debian systems, that system wide directory is
/etc/perl.)
If you give it no argument at all, it defaults to your personal config.
Returns the full path to the file if the config was saved, false otherwise. π
π options( type => TYPE )
Returns a list of all the valid config options for a specific type (like for example conf or program) β or false if that type doesn't exist. simple as that bestie π
π§ ACCESSORS π§
Any accessor that starts with a _ is marked private β regular users should never need to use these. like, don't touch, that's not for you π
For what items can be set and retrieved, go read the CPANPLUS::Config documentation. it's all spelled out there β¨
β get_SOMETHING( ITEM, [ITEM, ITEM, ... ] );
The get_* style accessors just retrieve one or more config options you want. that's it, that's the whole job πΈ
β set_SOMETHING( ITEM => VAL, [ITEM => VAL, ITEM => VAL, ... ] );
The set_* style accessors set the current value for one or more config options, and they return true on success, false on failure. π
β add_SOMETHING( ITEM => VAL, [ITEM => VAL, ITEM => VAL, ... ] );
The add_* style accessor adds a new key to a config key. cute π
Currently, the following accessors exist:
set|get_confβ simple configuration directives like verbosity and your favourite shell. iconic πset|get_programβ where your helper programs live. π_set|_get_buildβ locations of where to put what files for CPANPLUS. π₯_set|_get_sourceβ locations and names of source files locally. π_set|_get_mirrorβ locations and names of source files remotely. π_set|_get_fetchβ special settings pertaining to the fetching of files. π₯
π BUG REPORTS π
Please report bugs or other issues to <bug-cpanplus@rt.cpan.org<gt>.
yes that's literally how it's written in the original, i'm not touching it, i just work here π
π AUTHOR π
This module by Jos Boumans <kane@cpan.org>. giving credit where credit is due π«Ά
π 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::Config
and that's the whole page, bestie! this lil masterpiece comes to you from perl v5.40.1, dated 2025-03-01 π go forth and configure, you absolute icon πβ¨
π¦ 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