Dist::Zilla Takes To POD

Well another post-ette day again here in the Dist-Pen getting rid of one more chore.

Yep getting rid of one more chore the programmers least favorite thing next to code-reviews documenting your code. As good Perl programer we like to use POD as our format of choice and there are quite a few Modules out there that will help you a bit and some will get you started but alas the days of self documenting code are still not here.

Dist::Zilla does have a few plug-ins to help with documenting your code and as I really just want to get rid of some of the more boring chore work of documenting I decided on using 'Dist::Zilla::Plugin::PodWeaver'

Like all plugin I just add it to the '.ini', after I installed it,



[Manifest]
[CheckChangesHasContent]
++[PodWeaver]

Now I am not a regular user of Pod::Weaver so I am just using the default that comes built into the pug in and it should do at least add in the following
  • NAME, your package with your abstract if you have one

  • VERSION
  • AUTHOR and

  • COPYRIGHT & LICESNSE

Now looking at the very little bits of POD I have done so far I am missing only Author and the Copyright notices as I have the Name and Version present. After the 'dzil build' I have a look a the generated POD to see what I got.

Well the good news is this plug-in did not overwrite any of the original POD I had. It also added in the the Author and Copyright sections as it said it would and as a bonus it added __END__ above my =Pod command and the =encoding UTF-8 for me.

Now for the bad news it kept the Name and Version sections I had in the original document but shuffled them down to the bottom of my POD doc at least I still have those.

In the the end I am going to have to change my POD a little to keep the content I want, I think I will have to add a little to my present abstract get rid of the Name and Version sections.

The other good news is that it ignored the other packages embedded in Accessor.pm as I do not need a any POD for those. I also had two modules that I have yet to add any POD to and in my output dir both had the four sections it promises to deliver.

I could of course spend a good month or two learning all the ins and outs of PodWeaver but the four things it does for me save me a from a few little chores.

a46cf61a3d5c0661000c1323bb8d3a72--godzilla-party-godzilla-vs.jpg

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