Version 8 of Ultimate Package Blast-o-rama

Updated 2009-11-10 03:05:05 by hat0

Goals

To be the best package management system ever. To change the nature of package creation/distribution. To simplify all aspects of the process of writing and disseminating a library. To speed up parts of the system that are slow.

Subgoals for package writers

It should be easy to submit a package to the repository. The repository should have both a set of trusted, always-available packages (things like Itcl, modules from tcllib, etc), and a set of untrusted/unknown user-provided packages that anyone can contribute to.

Subgoals for application writers

It should be easy to access a package listed in the repository. The repository should handle dependencies automatically. The package shouldn't need to be installed on the local computer to be considered accessible and usable. The package manager should grab a package from a remote source if necessary.

Subgoals for end-users

It should be faster than the current tcl library load times. Root access shouldn't be necessary to add packages to one's local set of packages. The act of installing packages should never be necessary.

Assumptions

Packages, once installed, don't change often. The computer can do tedious work. The internet is available. Package writers have limited patience for boilerplate code/configuration. Simplying the package management system to where most cases just work with minimal effort is better than complicating the system to where all cases work with a lot of effort.

Inspiration

http://math.nist.gov/~DPorter/tcltk/oscon/

First cut at code

[package require Package]

The code is here: http://code.google.com/p/wub/source/browse/trunk/Utilities/Package.tcl

It completely replaces package with a version which tracks additions to (note: not subtractions from) ::auto_path. First time it ever runs it creates a database under ~/.tclpkg into which it stores all the packages it finds. Thereafter, it satisfies all [package require] calls from that database, never traversing the filesystem again, unless and until ::auto_path changes to include a new, as yet unseen, directory.

This is faster than filesystem traversal, and provides a centralised database of all known/seen packages. This speed comes at a cost, of course: changes to the underlying file system will *not* be noticed by or reflected in Package. As things stand, the database would have to be removed to reflect these changes when it is automatically rebuilt.