Trying to Organize Lessons Dependencies

At a previous post I wrote about steps to build a lesson manager. At this post you will find some words about issues for the first step are keep me wake at night.


This was based on the experience at Mozilla Science Lab Summer Sprint 2014. Notes about the lesson manager project are available.

Package Managers

We can divide package managers in three groups:

When the files are installed at /bin, /lib, /usr/bin, /usr/lib, /usr/share, ... E.g. apt-get, yum, ...
User Space
When the files are installed at ~/bin, ~/lib, ... E.g. gems, npm, ...
When the files are installed at the currently directory (or in a sub-directory of the currently directory). E.g. bower, component, ...

IMHO, the more suitable is the local ones because will be easy to users know where the lesson was installed.

Lessons Tree

Lessons has a dependence tree (black lines at the figure below) to be solved by the package manager but learners will use a path (read lines at the figure below) to read the lessons.

Ilustration of lesson tree.

One of the nice features of bower is that all the dependencies are installed as siblings, i.e.

$ bower install
$ ls -1

The problem is that our learner don’t have a tip for where he/she must start.

We can try solve the previous problem prepend a number to each directory, e.g.

$ ls -1

Unfortunately bower doesn’t has a feature to add the correctly number and include some number at the package metadata will easily make someone get duplicate numbers.

Create Metadata When Install Lesson

One of the features that bower doesn’t have (and we try to address at the sprint) is that when using

$ bower install

bower won’t create a metadata file to make possible update the lesson using

$ bower update