.\" Automatically generated by Pod::Man 4.09 (Pod::Simple 3.35) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" Set up some character translations and predefined strings. \*(-- will .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left .\" double quote, and \*(R" will give a right double quote. \*(C+ will .\" give a nicer C++. Capital omega is used to do unbreakable dashes and .\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff, .\" nothing in troff, for use with C<>. .tr \(*W- .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' .ie n \{\ . ds -- \(*W- . ds PI pi . if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch . if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch . ds L" "" . ds R" "" . ds C` "" . ds C' "" 'br\} .el\{\ . ds -- \|\(em\| . ds PI \(*p . ds L" `` . ds R" '' . ds C` . ds C' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is >0, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .\" .\" Avoid warning from groff about undefined register 'F'. .de IX .. .if !\nF .nr F 0 .if \nF>0 \{\ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . if !\nF==2 \{\ . nr % 0 . nr F 2 . \} .\} .\" ======================================================================== .\" .IX Title "Dist::Zilla::Role::PluginBundle::Easy 3pm" .TH Dist::Zilla::Role::PluginBundle::Easy 3pm "2018-05-07" "perl v5.26.2" "User Contributed Perl Documentation" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH "NAME" Dist::Zilla::Role::PluginBundle::Easy \- something that bundles a bunch of plugins easily .SH "VERSION" .IX Header "VERSION" version 6.012 .SH "SYNOPSIS" .IX Header "SYNOPSIS" .Vb 3 \& package Dist::Zilla::PluginBundle::Example; \& use Moose; \& with \*(AqDist::Zilla::Role::PluginBundle::Easy\*(Aq; \& \& sub configure { \& my $self = shift; \& \& $self\->add_plugins(\*(AqVersionFromModule\*(Aq); \& $self\->add_bundle(\*(AqBasic\*(Aq); \& } .Ve .SH "DESCRIPTION" .IX Header "DESCRIPTION" This role builds upon the PluginBundle role, adding methods to take most of the grunt work out of creating a bundle. It supplies the \f(CW\*(C`bundle_config\*(C'\fR method for you. In exchange, you must supply a \f(CW\*(C`configure\*(C'\fR method, which will store the bundle's configuration in the \f(CW\*(C`plugins\*(C'\fR attribute by calling \&\f(CW\*(C`add_plugins\*(C'\fR and/or \f(CW\*(C`add_bundle\*(C'\fR. .SH "ATTRIBUTES" .IX Header "ATTRIBUTES" .SS "name" .IX Subsection "name" This is the bundle name, taken from the Section passed to \&\f(CW\*(C`bundle_config\*(C'\fR. .SS "payload" .IX Subsection "payload" This hashref contains the bundle's parameters (if any), taken from the Section passed to \f(CW\*(C`bundle_config\*(C'\fR. .SS "plugins" .IX Subsection "plugins" This arrayref contains the configuration that will be returned by \&\f(CW\*(C`bundle_config\*(C'\fR. You normally modify this by using the \&\f(CW\*(C`add_plugins\*(C'\fR and \f(CW\*(C`add_bundle\*(C'\fR methods. .SH "METHODS" .IX Header "METHODS" .SS "add_plugins" .IX Subsection "add_plugins" .Vb 1 \& $self\->add_plugins(\*(AqPlugin1\*(Aq, [ Plugin2 => \e%plugin2config ]) .Ve .PP Use this method to add plugins to your bundle. .PP It is passed a list of plugin specifiers, which can be one of a few things: .IP "\(bu" 4 a plugin moniker (like you might provide in your config file) .IP "\(bu" 4 an arrayref of: \f(CW\*(C`[ $moniker, $plugin_name, \e%plugin_config ]\*(C'\fR .PP In the case of an arrayref, both \f(CW$plugin_name\fR and \f(CW\*(C`\e%plugin_config\*(C'\fR are optional. .PP The plugins are added to the config in the order given. .SS "add_bundle" .IX Subsection "add_bundle" .Vb 1 \& $self\->add_bundle(BundleName => \e%bundle_config) .Ve .PP Use this method to add all the plugins from another bundle to your bundle. If you omit \f(CW%bundle_config\fR, an empty hashref will be supplied. .SS "config_slice" .IX Subsection "config_slice" .Vb 1 \& $hash_ref = $self\->config_slice(arg1, { arg2 => \*(Aqplugin_arg2\*(Aq }) .Ve .PP Use this method to extract parameters from your bundle's \f(CW\*(C`payload\*(C'\fR so that you can pass them to a plugin or subsidiary bundle. It supports easy renaming of parameters, since a plugin may expect a parameter name that's too generic to be suitable for a bundle. .PP Each arg is either a key in \f(CW\*(C`payload\*(C'\fR, or a hashref that maps keys in \&\f(CW\*(C`payload\*(C'\fR to keys in the hash being constructed. If any specified key does not exist in \f(CW\*(C`payload\*(C'\fR, then it is omitted from the result. .SH "AUTHOR" .IX Header "AUTHOR" Ricardo \s-1SIGNES\s0 😏 .SH "COPYRIGHT AND LICENSE" .IX Header "COPYRIGHT AND LICENSE" This software is copyright (c) 2018 by Ricardo \s-1SIGNES.\s0 .PP This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.