Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re^5: What do I use to release a module to CPAN for the first time?

by tobyink (Canon)
on Oct 11, 2020 at 20:49 UTC ( [id://11122711]=note: print w/replies, xml ) Need Help??


in reply to Re^4: What do I use to release a module to CPAN for the first time?
in thread What do I use to release a module to CPAN for the first time?

It's pretty rare to need Dist::Zilla to provide a patch for someone else's distribution.

If they've got version control, make a clone of it, make your changes to the files in lib/bin/whatever, use prove -l ./t to run the test suite, and if it passes, submit your changes.

If no version control, untar the latest tarball from CPAN, and do the same.

If you're not going to build a tarball of your fixed version, you probably won't need Dist::Zilla.

  • Comment on Re^5: What do I use to release a module to CPAN for the first time?
  • Download Code

Replies are listed 'Best First'.
Re^6: What do I use to release a module to CPAN for the first time?
by Tux (Canon) on Oct 12, 2020 at 07:46 UTC

    I disagree.

    Many Dist::Zilla project only have a dist.int and no Makefile.PL, so you will need the whole bloody suite to get started anyway.

    However I applaud people using something to make their dist meet every standard and make their own lives easier to maintain and distribute their modules, IMHO Dist::Zilla is a (very) bad part of the toolchain to draw in fresh blood or make it easier for others (not using it) to submit changes.

    I have not seen a project that uses Dist::Zilla where I could get away without Dist::Zilla installed


    Enjoy, Have FUN! H.Merijn

      But to write a patch, test it, and submit it back to the maintainer, why would you need Makefile.PL?

      (I'm assuming a pure Perl distribution here; no XS.)

        Even if I know most about testing and I know about prove and yath, my usual start is always the same:

        1. Get the dist
          git clone / cpan + get / get the tgz
        2. Prepare
          $ cd Module-dir
          $ perl Makefile.PL

          If it complains about no Makefile.PL, curse loudly, check if there is a Build.PL

          $ perl Build.PL

          If there is no Build.PL either, curse even louder and ask myself the question if applying my patch is worth the trouble. If not, just give up.

        3. Test
          $ make test

          If it complains about missing Makefile, curse again and try Build.PL

          $ perl Build test

          If I really cared enough, and installed enough of dzil

          $ dzil test

          If that still complains about yet another missing plugin, give up and remove the dist dir: My time is valuable too.

        4. Hack
          If this module now passes all tests, check if my change still applies. (It might have been fixed in the git repo already). Otherwise, make the change, make a test case, update ChangeLog (or any other legal name) and submit a PR.

        Even as a seasoned perl programmer with enough knowledge to get the ball rolling, I see plenty of decision points where I would decide to leave the annoyance/bug to what it is and maybe just add an issue, which in most cases is much easier than going through the installation of dependencies I won't need for anything but this single module.


        Enjoy, Have FUN! H.Merijn

        At least for installing the prerequisites, and if the author uses Pod::Weaver, even a docpatch can't be applied by the module maintainer well.

      Then I suppose you have not seen any of my projects, or any using Dist::Milla, or David Golden's bundle, etc. -Dan

        Then your projects (and David's) most likely (also) have a proper Makefile.PL. In that case we (non Dist::Zilla users) won't even notice.

        I'll be a sport and not alter my original response, which states "Many" in the first sentence and lacks the addidion of "that not have a Makefile.PL" in the last sentence.


        Enjoy, Have FUN! H.Merijn

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11122711]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others sharing their wisdom with the Monastery: (4)
As of 2024-04-24 05:00 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found