Dist::Zilla::Util::EmulatePhase - Nasty tools for probing Dist::Zilla's internal state.
version 1.001002
Internal utility that de-duplicates references by ref-addr alone.
my $array = []; is_deeply( [ deduplicate( $array, $array ) ],[ $array ] )
Internal utility to expand various shorthand notations to full ones.
expand_modname('-MetaProvider') == 'Dist::Zilla::Role::MetaProvider'; expand_modname('=MetaNoIndex') == 'Dist::Zilla::Plugin::MetaNoIndex';
Probe Dist::Zilla's plugin registry and get items matching a specification
my @plugins = get_plugins({ zilla => $self->zilla, with => [qw( -MetaProvider -SomethingElse )], skip_with => [qw( -SomethingBadThatIsAMetaProvider )], isa => [qw( =SomePlugin =SomeOtherPlugin )], skip_isa => [qw( =OurPlugin )], });
Emulates Dist::Zilla's internal metadata aggregation and does it all again.
Minimum Usage:
my $metadata = get_metadata({ zilla => $self->zilla });
Extended usage:
my $metadata = get_metadata({ $zilla = $self->zilla, ... more params to get_plugins ... ... ie: ... with => [qw( -MetaProvider )], isa => [qw( =MetaNoIndex )], });
Emulates Dist::Zilla's internal prereqs aggregation and does it all again.
my $prereqs = get_prereqs({ zilla => $self->zilla });
my $metadata = get_prereqs({ $zilla = $self->zilla, ... more params to get_plugins ... ... ie: ... with => [qw( -PrereqSource )], isa => [qw( =AutoPrereqs )], });
Kent Fredric <kentnl@cpan.org>
This software is copyright (c) 2017 by Kent Fredric <kentnl@cpan.org>.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
To install Dist::Zilla::Util::EmulatePhase, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Dist::Zilla::Util::EmulatePhase
CPAN shell
perl -MCPAN -e shell install Dist::Zilla::Util::EmulatePhase
For more information on module installation, please visit the detailed CPAN module installation guide.