User prefixed packages #101

ryanramage opened this Issue Nov 24, 2012 · 1 comment


None yet
1 participant

ryanramage commented Nov 24, 2012

There are some broken packages in jam that are abandonware, with no way to contact the author. It probably is bad practice to remove them or replace them.

A solution would be to be able to upload a user prefixed package. The would not change, but one could do the following:

jam publish -u

And this would add the username to the doc id. so the package in couch would be username/package

And when installing one could do

jam install username/package

this would just look like 'package' was added so require(['package'], function(package){}) would work

The username would have to be stored somewhere for the upgrade so just add it to the package object.

var jam = {
    "packages": [
            "name": "eve",
            "location": "jam/eve",
            "main": "eve.js",
            "user" : "username"

An additional feature would be on the package details on the jam site, to list the alternate user prefixed packages, so a person could find better supported modules.


ryanramage commented Nov 26, 2012

I had a bash at this over the weekend. While it seemed simple at first, some of the complexities emerged. Also, I just re-read this thread:!topic/jamjs/LJ2uGL63ens

Seems like following the "provides" might be a better solution.

Some of the challenges I see with both solutions:

  • If you install a alternate package we have to make sure it is local to the project requesting it. We dont want it sitting in the local cache so on another project on the same machine will get the alternate version during an install/upgrade.
  • When making a new project, if there is an alternate version that you want to depend on (because the main one is broken), how would one specify it?
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment