I'm working with backups at the moment and instead of backing up the full disks it would be much more efficient for me just to backup the configuration of the system. So for the perl-section of things I would like to have a way to list installed modules and later reinstall those modules if needed.
I read How do I get a list of installed CPAN modules? about how to get the list and when reading perldoc -l install
I found this:
You can also use "cpan"'s "-a" switch to create an autobundle file that "CPAN.pm" understands and can use to re-install every module:
$ cpan -a
So I run cpan -a
and the last two rows of the output is:
Wrote bundle file
/home/ulf/.cpan/Bundle/Snapshot_2017_11_30_01.pm
And yes the file exists, but how do I use it to "re-install every module" on another host?
Note: I my have some preconceptions about this after working with requirement-files in pip so please bear with me.
If you open that bundle file with a text editor or perldoc
, you'll get instructions.
=head1 SYNOPSIS perl -MCPAN -e 'install Bundle::Snapshot_2017_11_30_00'
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With