Code Monkey home page Code Monkey logo

app-bundlefly's Introduction

--- WTF?!

I'm dissatisfied with the way CPAN tools install modules, especially
when they install several modules at once.

Modules in autobundle snapshots are installed alphabetically.
Dependencies are prepended as needed, and then they are installed
again later when they appear in the alphabet.

Distributions with a lot of dependencies tend to have the same issue
on a smaller scale.  Common dependencies such as Test::More may be
prepended and installed multiple times.

Yes, confirmations can be made automatic.

Yes, automatic confirmations suck less.

But redundantly installing modules, perhaps many times, still sucks.

--- So What?

Perlbrew lowers the effort to install new versions of Perl.  This is
awesome, and it's all fun and games, until one realizes that each new
Perl instance is missing all those necessary modules.

Autobundle snapshots reduce the effort needed to install a suite of
modules into a new Perl instance.  Create an autobundle snapshot from
one Perl instance, and install them into another.

These tools reduce the bletcherous redundancy inherent in autobundle
installs.  The process is greatly improved.

--- What You Get

This project includes two utilities to stop the sucking altogether.

"smartcpan" installs one or more modules and their dependencies so
that the dependencies come before the dependants.  This minimizes
(often eliminates) "prepend them to the queue" prompts and redundant
installations.

"smartbundle" does the same for all the modules in an autobundle
snapshot.

--- How It Works

CPANDB lets us quickly find the distributions for each module to
install.

It uses Graph::Directed to build dependency graphs for each module.
We subvert CPANDB to build a combined dependency graph for all
requested modules.

The graph is iterated through from successorless vertices
(distributions) up to the requested distributions.  Successorless
vertices are removed from the graph after each iteration.  This
continues until the entire graph has been installed and deleted.

The graph is based on distributions, but CPAN tools install modules.
CPANDB is used again to install a module for each distribution.

--- Troublesome

Log::Log4perl installs fine, but cpan doesn't seem to see it.  Every
time smartbundle is run, it installs Log::Log4perl again.  So much for
eliminating redundancy, eh?

app-bundlefly's People

Contributors

rcaputo avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

app-bundlefly's Issues

parallel install

Pedro Melo suggested:

Nice...

Just a couple of days ago I was hinting to miyagawa that I would love to see cpanm -j 6 :)

Maybe we could hack Bundlefly to manage multiple parallel CPAN clients instead...

If a module doesn't install, the whole process stops

I have LOTS of perl modules installed. Your script seems to be an improvement over running a Snapshot directly. However, there are always some modules that don't install properly. Mostly it's because some change to the module has caused one of the tests to fail. If I happened to need THAT module, it would be a big deal, and I would poke into it to see what's wrong and communicate with the author.

But, mostly, I don't care because (a) it's something I don't use very often (b) it will get fixed eventually, and (c) there are other modules that I need a lot more and they DO install. I use this installation process either when I have to upgrade/install my O/S and/or a new perl version.

Please, either allow for modules that don't pass their tests and report what dependencies they break, and/or allow me to indicate whether the installation script should halt when an error is encountered.

Thanks,
Chelmite

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.