CPANPLUS::Configure - Configuration interface for CPAN++



NAME

CPANPLUS::Configure - Configuration interface for CPAN++


SYNOPSIS

    use CPANPLUS::Configure;
    my $conf = new CPANPLUS::Configure;
    my @conf_options = $conf->subtypes('conf');
    $conf->load('options' => {'conf' => {'md5' => 1, 'flush' => 0}});
    my $_md5_setting = $conf->get_md5();
    $conf->set_debug(0);
    print $conf->dump();
    $conf->save();


DESCRIPTION

CPANPLUS::Configure can be used to view and manipulate configuration settings for CPANPLUS.


METHODS

new(conf => {CONFIGURATION})

The constructor will make a Config object. It will attempt to use a saved Config.pm if it exists. Arguments for 'conf' can be specified to replace those in the default Config for this object. The possible options are specified in set_conf().

If no Config.pm is found, or it is corrupt, you will be bumped to CPANPLUS::Configure::Setup to create one.

load(options => {OPTIONS})

Load is almost like the constructor, except that it takes a hash called 'options' which can contain keys such as 'conf'. Valid arguments which are passed will override Config settings.

save()

The save() function saves the Configure object to Config.pm, which is the default configuration for all CPANPLUS operations.

@subtypes = subtypes('conf')

This method will return a list of the subtypes of 'conf', which is the only public type. Every subtype in the array can be used as an argument in get_conf() and set_conf().

get_conf(SUBTYPE)

This function can be used to see the configuration setting of the named subtype.

Available subtypes are listed in set_conf().

set_conf(SUBTYPE => SETTING)

This method can be used to set any of the subtypes to new settings.


AUTHORS

This module by Joshua Boschert <jambe@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.


SEE ALSO

the CPANPLUS::Configure::Setup manpage

 CPANPLUS::Configure - Configuration interface for CPAN++