Public...igData(3pm)
π Public...igData(3pm) β aka Publican::ConfigData π
okay bestie, welcome to the manual page for Publican::ConfigData, and yeah the title got chopped up all cute in the header but it's giving Public...igData(3pm), from the User Contributed Perl Documentation corner of the world. she's a Perl module. she holds config. let's get into it π«Ά
β¨ NAME β¨
Publican::ConfigData β Configuration for Publican π
πΈ SYNOPSIS πΈ
like, here's the whole vibe in one go:
use Publican::ConfigData;
$value = Publican::ConfigData->config('foo');
$value = Publican::ConfigData->feature('bar');
@names = Publican::ConfigData->config_names;
@names = Publican::ConfigData->feature_names;
Publican::ConfigData->set_config(foo => $new_value);
Publican::ConfigData->set_feature(bar => $new_value);
Publican::ConfigData->write; # Save changes
look at that. immaculate. # Save changes β the girlies love persistence π
π¦ DESCRIPTION π¦
so this module holds the configuration data for the Publican module. that's her whole job. that's her main character energy.
she also hands you a programmatic interface for getting or setting that configuration data β so you can poke at it from code instead of, like, editing files by hand.
β οΈ real talk though: to actually make changes, you have to have write access to the Publican::ConfigData module itself. and before you go changing stuff, you should genuinely attempt to understand the repercussions of your actions. no cap. understand first, edit second. π«£
π METHODS π
config($name)
give her a string argument, she gives you back the value of the configuration item with that name. π
and if no such item exists? you get undef. the void. the nothingness. the silence. π
feature($name)
give her a string argument, she gives you back the value of the feature with that name. β¨
and again β no such feature? undef. she's not mad, she's just honest. π
set_config($name, $value)
sets the configuration item with the given name to the given value. π§
the value can be any Perl scalar that will serialize correctly using Data::Dumper. that includes references, objects (usually), and complex data structures β she's flexible like that, an icon.
but it probably does not include transient things like filehandles or sockets. so don't come at her with your socket. she will not hold it. π
set_feature($name, $value)
sets the feature with the given name to the given boolean value. π
the value gets converted to 0 or 1 automatically. so it's a yes/no situation and she's making it official.
config_names()
returns a list of all the names of config items currently defined in Publican::ConfigData. ποΈ
in scalar context? you get the number of items instead. one method, two moods.
feature_names()
returns a list of all the names of features currently defined in Publican::ConfigData. π
in scalar context, it's the number of features. same deal.
auto_feature_names()
returns a list of all the names of features whose availability is dynamically determined β‘ β or, in scalar context, the number of such features.
important detail: this does not include such features that have later been set to a fixed value. once it's locked in, it's locked in. periodt.
write()
commits any changes from set_config() and set_feature() to disk. πΎ
requires write access to the Publican::ConfigData module. so like, she needs the keys to the house before she can redecorate. π
π AUTHOR π
Publican::ConfigData was automatically created using Module::Build. π€
Module::Build was written by Ken Williams, but he holds no authorship claim or copyright claim to the contents of Publican::ConfigData. so like... the tool made it, the man built the tool, but the contents? not his, respectfully. π
okay that's the whole page bestie, you ate it up, go configure something responsibly πΈ
π this was perl v5.26.2, dated 2018-07-08, brought to you by the User Contributed Perl Documentation crew π
π¦ where this page comes from
- debian bookworm: publican 4.3.2-3 Β· Artistic-1.0-Perl OR GPL-2.0-or-later
- ubuntu jammy: publican 4.3.2-3 Β· Artistic-1.0-Perl OR GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms