Dist::Zilla Gets Used

Post-ette day here in the Dist-Pen

Today I am going to have a quick look at the [Requires] section plug-in. As the name implies this plug-in will add in a 'Requires' section in your POD. It will snoop though your '.pm' and '.pl' files with 'Module::Extract::Use' and lists these out.

Now I do have large number of uses in my code so I gave it a quick go by first installing the plug-in and then adding

[Generic / SYNOPSIS]
to my 'weaver.ini' file and then after a dzil clean and build I get;

=over 4
=item * L<Data::Dumper|Data::Dumper>
=item * L<Database::Accessor::Constants|Database::Accessor::Constants>
=item * L<File::Spec|File::Spec>
=item * L<Moose|Moose>
=item * L<Moose::Role|Moose::Role>
=item * L<Moose::Util|Moose::Util>
=item * L<MooseX::AccessorsOnly|MooseX::AccessorsOnly>
=item * L<MooseX::Aliases|MooseX::Aliases>
=item * L<MooseX::AlwaysCoerce|MooseX::AlwaysCoerce>
=item * L<MooseX::Constructor::AllErrors|MooseX::Constructor::AllErrors>
=item * L<MooseX::MetaDescription|MooseX::MetaDescription>
=item * L<namespace::autoclean|namespace::autoclean>
quite a long list. Now I can cut this list down by using the 'ignore' attribute and I would like to get rid of is 'Moose::Role' as it is bundle with Moose so all I need to do is

ignore =  Moose::Role
and after a clean and build I get;

=item * L<Moose|Moose>
=item * L<Moose::Util|Moose::Util>
You may add as many classes you want on this list just make sure they are separated by one space only.

This module is also useful to find unused modules as well. I see from the list above I still have a 'use Data::Dumper' someplace in my code and I should remove that before I do a release.

So that is the Post-ette for today.

Here is a silly Godzilla cat picture for you


Leave a comment

About byterock

user-pic Long time Perl guy, a few CPAN mods allot of work on DBD::Oracle and a few YAPC presentations