It's been quite a while in the making, but berrybrew version 1.23 now has the ability to "clone"** modules from one Perl instance into another.

It's currently a two-step process.

First, berrybrew switch into the Perl instance you want to export the module list from, then

berrybrew modules export

This will create a text document in a newly created modules directory within your Perl installation directory (by default, C:\berrybrew), named after the version of Perl you exported the module list from (eg: 5.20.3_64). This file has a single distribution name per line.

You can go ahead and edit this file (remove or add as many distribution names as you like), then when you're ready to import into a different Perl instance, simply berrybrew switch to it (note that as always, when switching Perls, you must close the command window and open a new one), then:

berrybrew modules import

That will display a list of all available export lists:

run the command with one of the following options: 5.16.3_64 5.20.3_64

...simply do what it says there:

berrybrew modules import 5.20.3_64

This can take a very, very long time, so it's advised to only import on a Perl instance that's newer than Perl you exported from. That, or significantly clean the file up for unneeded distributions.

Another benefit to this system, is that you can manually create a module "bundle" file within the mentioned "modules" directory, and add all distributions you prefer on all of your Perls. So:

You can remove all exported files by using the berrybrew clean modules command, but beware that if you have any manually created export files per above, they will be removed as well. I've got an issue open for the next release so that clean modules leaves any custom files in place.

Most of the other changes were quite minor this round, mainly back-end stuff, doc updates/fixes and test additions/modifications, along with an updated perls.json file with the newly released 5.30 version.

Feedback, as always, is welcome (as are any bug tickets).

Enjoy!

-stevieb

** - we don't actually clone or copy anything; on import, we use cpanm to do a full install of each listed distribution/module, each will have the most recently available production release installed.


In reply to berrybrew 1.23 released! by stevieb

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.